1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19 package org.apache.hadoop.hbase.rest;
20
21 import org.apache.hadoop.hbase.CompatibilitySingletonFactory;
22 import org.apache.hadoop.hbase.rest.MetricsRESTSource;
23 import org.apache.hadoop.hbase.rest.MetricsRESTSourceImpl;
24 import org.apache.hadoop.hbase.testclassification.SmallTests;
25 import org.apache.hadoop.hbase.testclassification.MetricsTests;
26 import org.junit.Test;
27 import org.junit.experimental.categories.Category;
28
29 import static org.junit.Assert.assertNotNull;
30 import static org.junit.Assert.assertTrue;
31
32
33
34
35 @Category({MetricsTests.class, SmallTests.class})
36 public class TestMetricsRESTSourceImpl {
37
38 @Test
39 public void ensureCompatRegistered() throws Exception {
40 assertNotNull(CompatibilitySingletonFactory.getInstance(MetricsRESTSource.class));
41 assertTrue(CompatibilitySingletonFactory.getInstance(MetricsRESTSource.class) instanceof MetricsRESTSourceImpl);
42 }
43
44 }