Java: add negative test case (IJ-CR-110898)

GitOrigin-RevId: 92159e1a64c8b3533d76c5134b4e0216a26b6aee
This commit is contained in:
Bas Leijdekkers
2023-07-19 16:08:18 +00:00
committed by intellij-monorepo-bot
parent 24893162b4
commit 69cae6f056
@@ -2,12 +2,16 @@ import org.intellij.lang.annotations.MagicConstant;
class TestAssignment {
interface States {
int INIT =0;
int INIT = 0;
int RUNNING = 1;
int STOPPED = 2;
}
@MagicConstant(valuesFromClass = States.class)
int state = <warning descr="Should be one of: States.INIT, States.RUNNING, States.STOPPED">0</warning>;
@MagicConstant(valuesFromClass = States.class)
int state2 = States.RUNNING;
public TestAssignment() {
this.state = <warning descr="Should be one of: States.INIT, States.RUNNING, States.STOPPED">0</warning>;
}