2 title: no-duplicate-case
9 If a `switch` statement has duplicate test expressions in `case` clauses, it is likely that a programmer copied a `case` clause but forgot to change the test expression.
13 This rule disallows duplicate test expressions in `case` clauses of `switch` statements.
15 Examples of **incorrect** code for this rule:
20 /*eslint no-duplicate-case: "error"*/
30 case 1: // duplicate test expression
41 case one: // duplicate test expression
52 case "1": // duplicate test expression
61 Examples of **correct** code for this rule:
66 /*eslint no-duplicate-case: "error"*/
107 ## When Not To Use It
109 In rare cases where identical test expressions in `case` clauses produce different values, which necessarily means that the expressions are causing and relying on side effects, you will have to disable this rule.
116 case i++: // eslint-disable-line no-duplicate-case