Repository: eslint/eslint
File: tests/lib/rules/no-restricted-properties.js (JavaScript)

Code before:
            code: "obj['#foo']",
            options: [{ property: "#foo" }],
            errors: [{
                messageId: "restrictedProperty",
                data: {
                    objectName: "",
                    propertyName: "#foo",
                    message: ""
                },
                type: "MemberExpression"
            }]
        }, {
            code: "const { bar: { bad } = {} } = foo;",
            options: [{ property: "bad" }],
            parserOptions: { ecmaVersion: 6 },
            errors: [{
                messageId: "restrictedProperty",
                data: {
                    propertyName: "bad",
                    message: ""
                }
            }]
        }, {
            code: "const { bar: { bad } } = foo;",
            options: [{ property: "bad" }],
            parserOptions: { ecmaVersion: 6 },
            errors: [{
                messageId: "restrictedProperty",
                data: {
                    propertyName: "bad",
                    message: ""
                }
            }]
        }, {
            code: "const { bad } = foo();",
            options: [{ property: "bad" }],
            parserOptions: { ecmaVersion: 6 },
            errors: [{
                messageId: "restrictedProperty",
                data: {
                    propertyName: "bad",
                    message: ""
                }
            }]
        }, {
            code: "({ bad } = foo());",
            options: [{ property: "bad" }],
            parserOptions: { ecmaVersion: 6 },
            errors: [{
                messageId: "restrictedProperty",
                data: {

Review comment (suggestion):
```suggestion
            languageOptions: { ecmaVersion: 6 },
```

Code after:
            code: "obj['#foo']",
            options: [{ property: "#foo" }],
            errors: [{
                messageId: "restrictedProperty",
                data: {
                    objectName: "",
                    propertyName: "#foo",
                    message: ""
                },
                type: "MemberExpression"
            }]
        }, {
            code: "const { bar: { bad } = {} } = foo;",
            options: [{ property: "bad" }],
            languageOptions: { ecmaVersion: 6 },
            errors: [{
                messageId: "restrictedProperty",
                data: {
                    propertyName: "bad",
                    message: ""
                }
            }]
        }, {
            code: "const { bar: { bad } } = foo;",
            options: [{ property: "bad" }],
            languageOptions: { ecmaVersion: 6 },
            errors: [{
                messageId: "restrictedProperty",
                data: {
                    propertyName: "bad",
                    message: ""
                }
            }]
        }, {
            code: "const { bad } = foo();",
            options: [{ property: "bad" }],
            languageOptions: { ecmaVersion: 6 },
            errors: [{
                messageId: "restrictedProperty",
                data: {
                    propertyName: "bad",
                    message: ""
                }
            }]
        }, {
            code: "({ bad } = foo());",
            options: [{ property: "bad" }],
            languageOptions: { ecmaVersion: 6 },
            errors: [{
                messageId: "restrictedProperty",
                data: {