/
githubmirror
/
eslint-plugin
Обзор
Документация
Войти
/
githubmirror
/
eslint-plugin
Код
Задачи
Вики
Пакеты
0
Релизы
0
Аналитика
Безопасность
0.1.2
tests/hardcodedConfigPath.test.ts
14 строк
402 B
Emile Bangma
Cleanup and format
04 июн 2025, 15:06
Не верифицирован
04 июн 2025, 15:06
29b4e71
Код
Авторство
О чём код?
import { RuleTester } from "@typescript-eslint/rule-tester"; import hardcodedConfigPathRule from "../lib/rules/hardcodedConfigPath.js"; const ruleTester = new RuleTester(); ruleTester.run("hardcoded-config-path", hardcodedConfigPathRule, { valid: [{ code: 'const config = ".config";' }], invalid: [ { code: 'const config = ".obsidian";', errors: [{ messageId: "configPath" }], }, ], });