]> git.proxmox.com Git - pve-eslint.git/blobdiff - eslint/tests/lib/rules/no-func-assign.js
import 7.12.1 upstream release
[pve-eslint.git] / eslint / tests / lib / rules / no-func-assign.js
index 662342158fba11a074e795f9b745547fe892d12b..85a6bdcc5bb0808197c07768d1929f81de95ae6f 100644 (file)
@@ -88,6 +88,14 @@ ruleTester.run("no-func-assign", rule, {
                 data: { name: "foo" },
                 type: "Identifier"
             }]
+        },
+        {
+            code: "var a = function foo() { foo = 123; };",
+            errors: [{
+                messageId: "isAFunction",
+                data: { name: "foo" },
+                type: "Identifier"
+            }]
         }
     ]
 });