diff --git a/package.json b/package.json
index d3ef63e66..0d33765a5 100644
--- a/package.json
+++ b/package.json
@@ -56,7 +56,7 @@
"eslint-utils": "^2.1.0",
"natural-compare": "^1.4.0",
"semver": "^7.3.2",
- "vue-eslint-parser": "^7.4.1"
+ "vue-eslint-parser": "^7.5.0"
},
"devDependencies": {
"@types/eslint": "^7.2.0",
diff --git a/tests/lib/rules/no-restricted-syntax.js b/tests/lib/rules/no-restricted-syntax.js
index e7b3d4480..662c2296f 100644
--- a/tests/lib/rules/no-restricted-syntax.js
+++ b/tests/lib/rules/no-restricted-syntax.js
@@ -36,6 +36,20 @@ tester.run('no-restricted-syntax', rule, {
message: 'Call expressions are not allowed.'
}
]
+ },
+
+ {
+ // https://github.com/vuejs/eslint-plugin-vue/issues/870
+ code: `
+
+
+ `,
+ options: [
+ {
+ selector: 'CallExpression > :nth-child(3)[value!=true]',
+ message: 'Third argument of interpolate must be true'
+ }
+ ]
}
],
invalid: [
@@ -148,6 +162,27 @@ tester.run('no-restricted-syntax', rule, {
'Call expressions are not allowed.',
'Call expressions are not allowed.'
]
+ },
+
+ {
+ // https://github.com/vuejs/eslint-plugin-vue/issues/870
+ code: `
+
+
+ `,
+ options: [
+ {
+ selector: 'CallExpression > :nth-child(3)[value!=true]',
+ message: 'Third argument of interpolate must be true'
+ }
+ ],
+ errors: [
+ {
+ message: 'Third argument of interpolate must be true',
+ line: 3,
+ column: 48
+ }
+ ]
}
]
})