Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line numberDiff line numberDiff line change
Expand Up@@ -268,16 +268,14 @@ public void writeTo(Appendable appendable) throws IOException {
json.name(CAPABILITIES);
json.beginObject();

json.name(DESIRED_CAPABILITIES);
json.write(first);

// Then write everything into the w3c payload. Because of the way we do this, it's easiest
// to just populate the "firstMatch" section. The spec says it's fine to omit the
// "alwaysMatch" field, so we do this.
json.name(ALWAYS_MATCH);
getW3C().forEach(json::write);

json.name(FIRST_MATCH);
json.beginArray();
//noinspection unchecked
getW3C().forEach(json::write);
json.beginObject();
json.endObject();
json.endArray();

json.endObject(); // Close "capabilities" object
Expand DownExpand Up@@ -547,4 +545,4 @@ private Map<String, Object> applyTransforms(Map<String, Object> caps) {
}
return toReturn;
}
}
}