You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Release: 1 Type: test Priority: high Blocks: — Blocked by: — Status: todo
Description
The script scripts/shell/linters/eslint.sh has no corresponding BATS test file. Every other linter script in scripts/shell/linters/ has a test counterpart in tests/linters/ (hadolint, htmlhint, markdownlint, shellcheck, stylelint, yamllint), but eslint.bats does not exist. This violates the project rule that every shell script must be covered by a BATS unit test (rules/process/ci-cd.md, section 9).
Motivation
Without tests, regressions in eslint.sh — config discovery logic, file collection, the ERROR_FOUND accumulator — will not be caught by CI. ESLint's config file detection is the most complex of all linter scripts: it checks seven possible filename variants (eslintrc.json, eslint.config.js, and five others). This logic is especially brittle without test coverage.
Note
The task was generated using the MCP server — prog-time/github-issues-server
Description
The script
scripts/shell/linters/eslint.shhas no corresponding BATS test file. Every other linter script inscripts/shell/linters/has a test counterpart intests/linters/(hadolint,htmlhint,markdownlint,shellcheck,stylelint,yamllint), buteslint.batsdoes not exist. This violates the project rule that every shell script must be covered by a BATS unit test (rules/process/ci-cd.md, section 9).Motivation
Without tests, regressions in
eslint.sh— config discovery logic, file collection, theERROR_FOUNDaccumulator — will not be caught by CI. ESLint's config file detection is the most complex of all linter scripts: it checks seven possible filename variants (eslintrc.json,eslint.config.js, and five others). This logic is especially brittle without test coverage.Target Structure
Checklist
tests/linters/eslint.batsmodelled ontests/linters/htmlhint.bats::error::No ESLint config file found.eslintrc.jsonfound, no JS/TS files → exit 0, output contains⚠️ No JS/TS files found. Skipping.eslint.config.jsfound (alternative format), all files pass → exit 0, output contains✅ All JS/TS files passed ESLint checks!❌ ESLint found issues!tests/helpers/common.bash(mock_tool/ conditional stub pattern matchinghtmlhint.bats)bats tests/linters/eslint.batslocally — all tests passbats --recursive tests/— the full test suite passesAffected Files
tests/linters/eslint.bats