From 9f84497737d8b19bc603f33ca62e25a00fa25755 Mon Sep 17 00:00:00 2001 From: Wanpeng Li Date: Fri, 24 Jan 2025 11:02:55 +0800 Subject: [PATCH] fix lint error --- .../eslint-plugin-tsv/src/rules/tspconfig-validation-rules.ts | 2 +- eng/tools/eslint-plugin-tsv/src/utils/rule-doc.ts | 1 - package-lock.json | 2 ++ 3 files changed, 3 insertions(+), 2 deletions(-) diff --git a/eng/tools/eslint-plugin-tsv/src/rules/tspconfig-validation-rules.ts b/eng/tools/eslint-plugin-tsv/src/rules/tspconfig-validation-rules.ts index 55b79b10b597..f4c2610ff76d 100644 --- a/eng/tools/eslint-plugin-tsv/src/rules/tspconfig-validation-rules.ts +++ b/eng/tools/eslint-plugin-tsv/src/rules/tspconfig-validation-rules.ts @@ -163,7 +163,7 @@ const args: CreateCodeGenSDKRuleArgs[] = [ exampleValue: "azure-aaa", extraExplanation: "The 'package-dir' should be a string that starts with 'azure', followed by one or more '-' segments. Each segment can contains letters, digits, or underscores", - condition: (tspconfig: TypeSpecConfig, context: Rule.RuleContext) => + condition: (tspconfig: TypeSpecConfig, _: Rule.RuleContext) => isAzureSDK(tspconfig, emitters.java), }, // python diff --git a/eng/tools/eslint-plugin-tsv/src/utils/rule-doc.ts b/eng/tools/eslint-plugin-tsv/src/utils/rule-doc.ts index 4a62792f0c11..1ffef72bee77 100644 --- a/eng/tools/eslint-plugin-tsv/src/utils/rule-doc.ts +++ b/eng/tools/eslint-plugin-tsv/src/utils/rule-doc.ts @@ -1,5 +1,4 @@ import { KeyType, RuleDocument } from "../interfaces/rule-interfaces.js"; -import { emitters } from "./constants.js"; import { stringify } from "yaml"; function createDescriptionDocumentBlock( diff --git a/package-lock.json b/package-lock.json index 821663bc1e52..6791bde87d86 100644 --- a/package-lock.json +++ b/package-lock.json @@ -52,10 +52,12 @@ "name": "@azure-tools/eslint-plugin-tsv", "dev": true, "dependencies": { + "ajv": "^8.17.1", "yaml-eslint-parser": "^1.2.3" }, "devDependencies": { "@types/node": "^18.19.31", + "@vitest/coverage-v8": "^2.0.4", "eslint": "^9.17.0", "memfs": "^4.15.0", "rimraf": "^5.0.10",