StandAloneProfiler { public int getProfileCount() { return (config == null) ? 0: config.getProfiles().size(); } StandAloneProfiler(ProfilerConfig config,
                            long periodDurationMillis,
                            long profileTimeToLiveMillis,
                            long maxNumberOfRoutes,
                            Context context); void apply(JSONObject message); List<ProfileMeasurement> flush(); ProfilerConfig getConfig(); int getProfileCount(); int getMessageCount(); int getRouteCount(); @Override String toString();  }
@Test public void testProfileCount() throws Exception { { StandAloneProfiler profiler = createProfiler(noProfiles); assertEquals(0, profiler.getProfileCount()); } { StandAloneProfiler profiler = createProfiler(oneProfile); assertEquals(1, profiler.getProfileCount()); } { StandAloneProfiler profiler = createProfiler(twoProfiles); assertEquals(2, profiler.getProfileCount()); } }