@Test
public void testMetricTokensLevelZero() {

    List<MetricSchemaRecord> records = new ArrayList<>();
    records.add(new MetricSchemaRecord(null, "scope1", "metric0", "source", "unittest"));
    records.add(new MetricSchemaRecord(null, "scope1", "metric1", "source", "unittest"));
    records.add(new MetricSchemaRecord(null, "scope2", "metric2", "source", "unittest"));
    records.add(new MetricSchemaRecord(null, "scope2", "metric3", "source", "unittest"));
    records.add(new MetricSchemaRecord(null, "scope2", "metric4", "source", "unittest"));
    SortedSet<String> metrics = MetricSchemaRecordTokenizer.GetUniqueTokens(records, SchemaService.RecordType.METRIC, 0);
    assertTrue(metrics.size() == 5);
    assertTrue(metrics.contains("metric0"));
    assertTrue(metrics.contains("metric4"));
}