1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16 package org.kuali.rice.core.test;
17
18 import java.lang.annotation.Documented;
19 import java.lang.annotation.ElementType;
20 import java.lang.annotation.Inherited;
21 import java.lang.annotation.Retention;
22 import java.lang.annotation.RetentionPolicy;
23 import java.lang.annotation.Target;
24
25 import org.junit.Test;
26 import org.kuali.rice.test.data.PerSuiteUnitTestData;
27 import org.kuali.rice.test.data.PerTestUnitTestData;
28 import org.kuali.rice.test.data.UnitTestData;
29
30
31
32
33
34
35
36 @PerSuiteUnitTestData(
37 overrideSuperClasses = true,
38 value = {@UnitTestData("insert into " + AnnotationTestParent.TEST_TABLE_NAME + " (COL) values ('3')"),
39 @UnitTestData(filename = "classpath:org/kuali/rice/test/DataLoaderAnnotationTestData.sql")
40 })
41 @DataLoaderAnnotationOverrideTest.Nothing
42 public class DataLoaderAnnotationOverrideTest extends AnnotationTestParent {
43
44
45 @Documented
46 @Target({ElementType.TYPE, ElementType.METHOD})
47 @Retention(RetentionPolicy.RUNTIME)
48 @Inherited
49 public static @interface Nothing {
50 }
51
52 @Test public void testParentAndSubClassImplementation() throws Exception {
53
54
55
56 verifyCount("3", 1, "https://jira.kuali.org/browse/KULRICE-9283");
57
58
59 verifyCount("4", 1);
60
61
62 verifyNonExistent("1");
63
64
65 verifyNonExistent("2");
66 }
67
68 }