8025537: Convert 2 javac/enumdeclarations tests in jtreg for regression ws

Reviewed-by: jjg
This commit is contained in:
Sonali Goel 2013-09-27 10:39:52 -07:00
parent e0f4378a6c
commit 475b209cf7
6 changed files with 57 additions and 0 deletions

View file

@ -0,0 +1,20 @@
/**
* @test /nodynamiccopyright/
* @bug 8025537 5028491
* @author sogoel
* @summary enum constants should precede other enum members
* @compile/fail/ref=EnumMembersOrder.out -XDrawDiagnostics EnumMembersOrder.java
*/
enum Days {
Days(String d) { day = d; } // constructor
// enum constants
WEEKEND("SAT"),
WEEKDAY("MON");
private String day;
}