langtools/test/tools/javac/processing/model/element/repeatingAnnotations/RepeatableOfficialContainerBasicTest.java
equal
deleted
inserted
replaced
1 /* |
1 /* |
2 * Copyright (c) 2013, 2015, Oracle and/or its affiliates. All rights reserved. |
2 * Copyright (c) 2013, 2016, Oracle and/or its affiliates. All rights reserved. |
3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. |
3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. |
4 * |
4 * |
5 * This code is free software; you can redistribute it and/or modify it |
5 * This code is free software; you can redistribute it and/or modify it |
6 * under the terms of the GNU General Public License version 2 only, as |
6 * under the terms of the GNU General Public License version 2 only, as |
7 * published by the Free Software Foundation. |
7 * published by the Free Software Foundation. |
21 * questions. |
21 * questions. |
22 */ |
22 */ |
23 |
23 |
24 /* |
24 /* |
25 * @test |
25 * @test |
26 * @bug 8004822 |
26 * @bug 8004822 8163113 |
27 * @author mnunez |
27 * @author mnunez |
28 * @summary Language model api test basics for repeating annotations |
28 * @summary Language model api test basics for repeating annotations |
29 * @library /tools/javac/lib |
29 * @library /tools/javac/lib |
30 * @library supportingAnnotations |
30 * @library supportingAnnotations |
31 * @modules java.compiler |
31 * @modules java.compiler |
50 }) |
50 }) |
51 @ExpectedContainer( |
51 @ExpectedContainer( |
52 value = BarContainer.class, |
52 value = BarContainer.class, |
53 getAnnotation = "null", |
53 getAnnotation = "null", |
54 getAnnotationsByType = { |
54 getAnnotationsByType = { |
55 "@BarContainer(value=[@Bar(value=1)])", |
55 "@BarContainer(value={@Bar(value=1)})", |
56 "@BarContainer(value=[@Bar(value=2)])"}) |
56 "@BarContainer(value={@Bar(value=2)})"}) |
57 @BarContainer(value = {@Bar(value = 1)}) |
57 @BarContainer(value = {@Bar(value = 1)}) |
58 @BarContainer(value = {@Bar(value = 2)}) |
58 @BarContainer(value = {@Bar(value = 2)}) |
59 class RepeatableOfficialContainerBasicTest { |
59 class RepeatableOfficialContainerBasicTest { |
60 |
60 |
61 @ExpectedBase( |
61 @ExpectedBase( |
74 }) |
74 }) |
75 @ExpectedContainer( |
75 @ExpectedContainer( |
76 value = BarContainer.class, |
76 value = BarContainer.class, |
77 getAnnotation = "null", |
77 getAnnotation = "null", |
78 getAnnotationsByType = { |
78 getAnnotationsByType = { |
79 "@BarContainer(value=[@Bar(value=1)])", |
79 "@BarContainer(value={@Bar(value=1)})", |
80 "@BarContainer(value=[@Bar(value=2)])"}) |
80 "@BarContainer(value={@Bar(value=2)})"}) |
81 @BarContainer(value = {@Bar(value = 1)}) |
81 @BarContainer(value = {@Bar(value = 1)}) |
82 @BarContainer(value = {@Bar(value = 2)}) |
82 @BarContainer(value = {@Bar(value = 2)}) |
83 int testField = 0; |
83 int testField = 0; |
84 |
84 |
85 @ExpectedBase( |
85 @ExpectedBase( |
98 }) |
98 }) |
99 @ExpectedContainer( |
99 @ExpectedContainer( |
100 value = BarContainer.class, |
100 value = BarContainer.class, |
101 getAnnotation = "null", |
101 getAnnotation = "null", |
102 getAnnotationsByType = { |
102 getAnnotationsByType = { |
103 "@BarContainer(value=[@Bar(value=1)])", |
103 "@BarContainer(value={@Bar(value=1)})", |
104 "@BarContainer(value=[@Bar(value=2)])"}) |
104 "@BarContainer(value={@Bar(value=2)})"}) |
105 @BarContainer(value = {@Bar(value = 1)}) |
105 @BarContainer(value = {@Bar(value = 1)}) |
106 @BarContainer(value = {@Bar(value = 2)}) |
106 @BarContainer(value = {@Bar(value = 2)}) |
107 void testMethod() {} |
107 void testMethod() {} |
108 } |
108 } |