Skip to content

Commit

Permalink
Write gv2-3 capability.
Browse files Browse the repository at this point in the history
  • Loading branch information
alan-signal committed Sep 28, 2020
1 parent caf8bb3 commit e8ef621
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -119,7 +119,7 @@ public static class Capabilities {
@JsonProperty
private boolean uuid;

@JsonProperty("gv2-2")
@JsonProperty("gv2-3")
private boolean gv2;

@JsonProperty
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,19 +28,19 @@ public void can_write_account_attributes() {
"\"unidentifiedAccessKey\":\"AAAAAAAAAAAAAA==\"," +
"\"unrestrictedUnidentifiedAccess\":false," +
"\"discoverableByPhoneNumber\":false," +
"\"capabilities\":{\"uuid\":true,\"storage\":true,\"gv2-2\":true}}", json);
"\"capabilities\":{\"uuid\":true,\"storage\":true,\"gv2-3\":true}}", json);
}

@Test
public void gv2_true() {
String json = JsonUtil.toJson(new AccountAttributes.Capabilities(false, true, false));
assertEquals("{\"uuid\":false,\"storage\":false,\"gv2-2\":true}", json);
assertEquals("{\"uuid\":false,\"storage\":false,\"gv2-3\":true}", json);
}

@Test
public void gv2_false() {
String json = JsonUtil.toJson(new AccountAttributes.Capabilities(false, false, false));
assertEquals("{\"uuid\":false,\"storage\":false,\"gv2-2\":false}", json);
assertEquals("{\"uuid\":false,\"storage\":false,\"gv2-3\":false}", json);
}

}

0 comments on commit e8ef621

Please sign in to comment.