From a41f7db1fc16e387573f72f2d21e798d7719f7b7 Mon Sep 17 00:00:00 2001 From: Gaston Thea Date: Tue, 5 Sep 2023 17:36:20 -0300 Subject: [PATCH] Fix json key --- .../android/client/telemetry/model/MethodExceptions.java | 4 ++-- .../split/android/client/telemetry/model/MethodLatencies.java | 4 ++-- .../client/telemetry/TelemetryStatsBodySerializerTest.java | 2 +- 3 files changed, 5 insertions(+), 5 deletions(-) diff --git a/src/main/java/io/split/android/client/telemetry/model/MethodExceptions.java b/src/main/java/io/split/android/client/telemetry/model/MethodExceptions.java index ff87dedab..0a936f565 100644 --- a/src/main/java/io/split/android/client/telemetry/model/MethodExceptions.java +++ b/src/main/java/io/split/android/client/telemetry/model/MethodExceptions.java @@ -22,10 +22,10 @@ public class MethodExceptions { @SerializedName("tfs") private long treatmentsByFlagSets; - @SerializedName("tfc") + @SerializedName("tcf") private long treatmentsWithConfigByFlagSet; - @SerializedName("tfcs") + @SerializedName("tcfs") private long treatmentsWithConfigByFlagSets; @SerializedName("tr") diff --git a/src/main/java/io/split/android/client/telemetry/model/MethodLatencies.java b/src/main/java/io/split/android/client/telemetry/model/MethodLatencies.java index 3c9d95391..15cc73fe8 100644 --- a/src/main/java/io/split/android/client/telemetry/model/MethodLatencies.java +++ b/src/main/java/io/split/android/client/telemetry/model/MethodLatencies.java @@ -24,10 +24,10 @@ public class MethodLatencies { @SerializedName("tfs") private List treatmentsByFlagSets; - @SerializedName("tfc") + @SerializedName("tcf") private List treatmentsWithConfigByFlagSet; - @SerializedName("tfcs") + @SerializedName("tcfs") private List treatmentsWithConfigByFlagSets; @SerializedName("tr") diff --git a/src/test/java/io/split/android/client/telemetry/TelemetryStatsBodySerializerTest.java b/src/test/java/io/split/android/client/telemetry/TelemetryStatsBodySerializerTest.java index b363cc2e4..1a6ec1cd4 100644 --- a/src/test/java/io/split/android/client/telemetry/TelemetryStatsBodySerializerTest.java +++ b/src/test/java/io/split/android/client/telemetry/TelemetryStatsBodySerializerTest.java @@ -30,7 +30,7 @@ public void setUp() { public void jsonIsBuiltAsExpected() { String serializedStats = telemetryStatsBodySerializer.serialize(getMockStats()); - assertEquals("{\"lS\":{\"sp\":1000,\"ms\":2000,\"im\":3000,\"ic\":4000,\"ev\":5000,\"te\":6000,\"to\":7000},\"mL\":{\"t\":[0,0,2,0],\"ts\":[0,0,3,0],\"tc\":[0,0,5,0],\"tcs\":[0,0,4,0],\"tf\":[1,0,0,0],\"tfs\":[2,0,0,0],\"tfc\":[3,0,0,0],\"tfcs\":[4,0,0,0],\"tr\":[0,0,1,0]},\"mE\":{\"t\":2,\"ts\":3,\"tc\":5,\"tcs\":4,\"tf\":10,\"tfs\":20,\"tfc\":30,\"tfcs\":40,\"tr\":1},\"hE\":{},\"hL\":{\"sp\":[0,0,3,0],\"ms\":[0,0,5,0],\"im\":[0,0,1,0],\"ic\":[0,0,4,0],\"ev\":[0,0,2,0],\"te\":[1,0,0,0],\"to\":[0,0,6,0]},\"tR\":4,\"aR\":5,\"iQ\":2,\"iDe\":5,\"iDr\":4,\"spC\":456,\"seC\":4,\"skC\":1,\"sL\":2000,\"eQ\":4,\"eD\":2,\"sE\":[{\"e\":0,\"t\":5000},{\"e\":20,\"d\":4,\"t\":2000}],\"t\":[\"tag1\",\"tag2\"],\"ufs\":{\"sp\":4,\"ms\":8}}", serializedStats); + assertEquals("{\"lS\":{\"sp\":1000,\"ms\":2000,\"im\":3000,\"ic\":4000,\"ev\":5000,\"te\":6000,\"to\":7000},\"mL\":{\"t\":[0,0,2,0],\"ts\":[0,0,3,0],\"tc\":[0,0,5,0],\"tcs\":[0,0,4,0],\"tf\":[1,0,0,0],\"tfs\":[2,0,0,0],\"tcf\":[3,0,0,0],\"tcfs\":[4,0,0,0],\"tr\":[0,0,1,0]},\"mE\":{\"t\":2,\"ts\":3,\"tc\":5,\"tcs\":4,\"tf\":10,\"tfs\":20,\"tcf\":30,\"tcfs\":40,\"tr\":1},\"hE\":{},\"hL\":{\"sp\":[0,0,3,0],\"ms\":[0,0,5,0],\"im\":[0,0,1,0],\"ic\":[0,0,4,0],\"ev\":[0,0,2,0],\"te\":[1,0,0,0],\"to\":[0,0,6,0]},\"tR\":4,\"aR\":5,\"iQ\":2,\"iDe\":5,\"iDr\":4,\"spC\":456,\"seC\":4,\"skC\":1,\"sL\":2000,\"eQ\":4,\"eD\":2,\"sE\":[{\"e\":0,\"t\":5000},{\"e\":20,\"d\":4,\"t\":2000}],\"t\":[\"tag1\",\"tag2\"],\"ufs\":{\"sp\":4,\"ms\":8}}", serializedStats); } private Stats getMockStats() {