@Override public MetricNameValidator createMetricNameValidator() { return new MetricNameValidator(METRIC_NAME_LIMIT, INSTANCE_NAME_LIMIT); } }
@Override public MetricNameValidator createMetricNameValidator() { return new MetricNameValidator(STRING_BLOCK_LIMIT, STRING_BLOCK_LIMIT); } }
@Before public void setUp() throws Exception { validator = new MetricNameValidator(NAME_LIMIT, DOMAIN_LIMIT); }
@Test public void mmvVersion2_shouldCreateAVersionMetricValidator() { MetricNameValidator actual = MMV_VERSION2.createMetricNameValidator(); MetricNameValidator expected = new MetricNameValidator(MMV2_NAME_LIMIT, MMV2_INSTANCE_LIMIT); assertReflectionEquals(expected, actual); }
@Test public void mmvVersion1_shouldCreateAVersion1MetricValidator() { MetricNameValidator actual = MMV_VERSION1.createMetricNameValidator(); MetricNameValidator expected = new MetricNameValidator(MMV1_NAME_LIMIT, MMV1_DOMAIN_LIMIT); assertReflectionEquals(expected, actual); }