use of com.google.firebase.perf.v1.PerfMetric in project firebase-android-sdk by firebase.
the class TransportManagerTest method logGaugeMetric_globalCustomAttributesAreNotAdded.
@Test
public void logGaugeMetric_globalCustomAttributesAreNotAdded() {
FirebasePerformance.getInstance().putAttribute("test_key1", "test_value1");
FirebasePerformance.getInstance().putAttribute("test_key2", "test_value2");
GaugeMetric validGauge = createValidGaugeMetric();
testTransportManager.log(validGauge);
fakeExecutorService.runAll();
PerfMetric loggedPerfMetric = getLastLoggedEvent(times(1));
assertThat(loggedPerfMetric.getGaugeMetric()).isEqualTo(validGauge);
validateApplicationInfo(loggedPerfMetric, ApplicationProcessState.APPLICATION_PROCESS_STATE_UNKNOWN);
assertThat(loggedPerfMetric.getApplicationInfo().getCustomAttributesCount()).isEqualTo(0);
}
Aggregations