Repository: eslint/eslint
File: tests/lib/rules/logical-assignment-operators.js (JavaScript)

Code before:
        {
            code: "a = a || b || c",
            output: "a ||= b || c",
            options: ["always"],
            errors: [{
                messageId: "assignment",
                type: "AssignmentExpression",
                data: { operator: "||=" },
                suggestions: []
            }]
        },
        {
            code: "a = a && b && c",
            output: "a &&= b && c",
            options: ["always"],
            errors: [{
                messageId: "assignment",
                type: "AssignmentExpression",
                data: { operator: "&&=" },
                suggestions: []
            }]
        },
        {
            code: "a = a || b && c",
            output: "a ||= b && c",
            options: ["always"],
            errors: [{
                messageId: "assignment",
                type: "AssignmentExpression",
                data: { operator: "||=" },
                suggestions: []
            }]
        },
        {
            code: "a = a || b || c || d",
            output: "a ||= b || c || d",
            options: ["always"],
            errors: [{
                messageId: "assignment",
                type: "AssignmentExpression",
                data: { operator: "||=" },
                suggestions: []
            }]
        },
        {
            code: "a = a && b && c && d",
            output: "a &&= b && c && d",
            options: ["always"],
            errors: [{
                messageId: "assignment",
                type: "AssignmentExpression",

Review comment (suggestion):
```suggestion
        },
        {
            code: "a = a ?? b ?? c",
            output: "a ??= b ?? c",
            options: ["always"],
            errors: [{
                messageId: "assignment",
                type: "AssignmentExpression",
                data: { operator: "??=" },
                suggestions: []
            }]
        },
```

To confirm that this intentionally applies to `??` as well. (I think all other tests are with `||` or `&&`)

Code after:
            }]
        },

        // 3 or more operands
        {
            code: "a = a || b || c",
            output: "a ||= b || c",
            options: ["always"],
            errors: [{
                messageId: "assignment",
                type: "AssignmentExpression",
                data: { operator: "||=" },
                suggestions: []
            }]
        },
        {
            code: "a = a && b && c",
            output: "a &&= b && c",
            options: ["always"],
            errors: [{
                messageId: "assignment",
                type: "AssignmentExpression",
                data: { operator: "&&=" },
                suggestions: []
            }]
        },
        {
            code: "a = a ?? b ?? c",
            output: "a ??= b ?? c",
            options: ["always"],
            errors: [{
                messageId: "assignment",
                type: "AssignmentExpression",
                data: { operator: "??=" },
                suggestions: []
            }]
        },
        {
            code: "a = a || b && c",
            output: "a ||= b && c",
            options: ["always"],
            errors: [{
                messageId: "assignment",
                type: "AssignmentExpression",
                data: { operator: "||=" },
                suggestions: []
            }]
        },
        {
            code: "a = a || b || c || d",
            output: "a ||= b || c || d",