mirror of
https://github.com/oxen-io/session-android.git
synced 2025-08-11 10:07:25 +00:00
Write gv2-3 capability.
This commit is contained in:
@@ -119,7 +119,7 @@ public class AccountAttributes {
|
||||
@JsonProperty
|
||||
private boolean uuid;
|
||||
|
||||
@JsonProperty("gv2-2")
|
||||
@JsonProperty("gv2-3")
|
||||
private boolean gv2;
|
||||
|
||||
@JsonProperty
|
||||
|
@@ -28,19 +28,19 @@ public final class AccountAttributesTest {
|
||||
"\"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);
|
||||
}
|
||||
|
||||
}
|
Reference in New Issue
Block a user