@sarj/eslint-plugin 16.35.0 → 16.35.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.cjs CHANGED
@@ -1876,7 +1876,7 @@ var NO_TEST_COMMENTS_DOCUMENTATION = {
1876
1876
  limitations: [
1877
1877
  "Checks actual line and block comment tokens in recognized maintained test files, including test fixtures; strings and template text remain unchanged. Generated/vendor files are excluded.",
1878
1878
  "Legal notices, shebangs, TypeScript triple-slash references, coverage/build annotations and explicit lint/type/test/formatter directives remain allowed. Ordinary prose embedded in a directive remains the owning tool's responsibility.",
1879
- "The automatic fix removes comments and adjacent padding while retaining every line ending and necessary token boundary; it does not rename tests or remove executable statements. Ambiguous hyphen/underscore test basenames require a runtime testing-framework import; ordinary rule implementations ending in -test are preserved."
1879
+ "The automatic fix removes comments and adjacent padding while retaining every line ending and necessary token boundary; it does not rename tests or remove executable statements. Bare integration/e2e directories and ambiguous hyphen/underscore test basenames require another concrete test-path signal or a runtime testing-framework import; ordinary production integration modules and rule implementations ending in -test are preserved."
1880
1880
  ],
1881
1881
  examples: [
1882
1882
  { id: "narrated-assertion", title: "Put behavior in the test name", outcome: "match", files: [{ path: "src/request.test.ts", source: "expect(result.status).toBe(409); // Confirm the rejected request\n" }], fixedFiles: [{ path: "src/request.test.ts", source: "expect(result.status).toBe(409);\n" }], focusPath: "src/request.test.ts", expectedCount: 1, public: true },
@@ -1900,8 +1900,8 @@ var no_test_comments_default = createRule({
1900
1900
  create(context) {
1901
1901
  if (!isTestFile(context) || isGeneratedFile(context, context.sourceCode.text)) return {};
1902
1902
  const filename = scopedFilename(context);
1903
- const unambiguous = /(?:^|\/)(?:tests?|__tests__|fixtures|__fixtures__|__mocks__|integration|e2e)\//u.test(filename) || /\.(?:test|spec|e2e|integration)\.[cm]?[jt]sx?$/u.test(filename);
1904
- const framework = context.sourceCode.ast.body.some((statement) => statement.type === import_utils18.AST_NODE_TYPES.ImportDeclaration && statement.importKind !== "type" && ["vitest", "@jest/globals", "@playwright/test", "bun:test", "node:test"].includes(statement.source.value));
1903
+ const unambiguous = /(?:^|\/)(?:tests?|__tests__|fixtures|__fixtures__|__mocks__)\//u.test(filename) || /\.(?:test|spec|e2e|integration)\.[cm]?[jt]sx?$/u.test(filename);
1904
+ const framework = context.sourceCode.ast.body.some((statement) => statement.type === import_utils18.AST_NODE_TYPES.ImportDeclaration && statement.importKind !== "type" && (statement.specifiers.length === 0 || statement.specifiers.some((specifier) => specifier.type !== import_utils18.AST_NODE_TYPES.ImportSpecifier || specifier.importKind !== "type")) && ["vitest", "@jest/globals", "@playwright/test", "bun:test", "node:test"].includes(statement.source.value));
1905
1905
  if (!unambiguous && !framework) return {};
1906
1906
  return {
1907
1907
  Program() {
@@ -3900,7 +3900,7 @@ function isSearchParamReceiver(call, services) {
3900
3900
  // package.json
3901
3901
  var package_default = {
3902
3902
  name: "@sarj/eslint-plugin",
3903
- version: "16.35.0",
3903
+ version: "16.35.1",
3904
3904
  packageManager: "npm@12.2.1",
3905
3905
  description: "Custom ESLint rules for hypermodern TypeScript / React / Next.js projects",
3906
3906
  type: "module",
package/dist/index.js CHANGED
@@ -1825,7 +1825,7 @@ var NO_TEST_COMMENTS_DOCUMENTATION = {
1825
1825
  limitations: [
1826
1826
  "Checks actual line and block comment tokens in recognized maintained test files, including test fixtures; strings and template text remain unchanged. Generated/vendor files are excluded.",
1827
1827
  "Legal notices, shebangs, TypeScript triple-slash references, coverage/build annotations and explicit lint/type/test/formatter directives remain allowed. Ordinary prose embedded in a directive remains the owning tool's responsibility.",
1828
- "The automatic fix removes comments and adjacent padding while retaining every line ending and necessary token boundary; it does not rename tests or remove executable statements. Ambiguous hyphen/underscore test basenames require a runtime testing-framework import; ordinary rule implementations ending in -test are preserved."
1828
+ "The automatic fix removes comments and adjacent padding while retaining every line ending and necessary token boundary; it does not rename tests or remove executable statements. Bare integration/e2e directories and ambiguous hyphen/underscore test basenames require another concrete test-path signal or a runtime testing-framework import; ordinary production integration modules and rule implementations ending in -test are preserved."
1829
1829
  ],
1830
1830
  examples: [
1831
1831
  { id: "narrated-assertion", title: "Put behavior in the test name", outcome: "match", files: [{ path: "src/request.test.ts", source: "expect(result.status).toBe(409); // Confirm the rejected request\n" }], fixedFiles: [{ path: "src/request.test.ts", source: "expect(result.status).toBe(409);\n" }], focusPath: "src/request.test.ts", expectedCount: 1, public: true },
@@ -1849,8 +1849,8 @@ var no_test_comments_default = createRule({
1849
1849
  create(context) {
1850
1850
  if (!isTestFile(context) || isGeneratedFile(context, context.sourceCode.text)) return {};
1851
1851
  const filename = scopedFilename(context);
1852
- const unambiguous = /(?:^|\/)(?:tests?|__tests__|fixtures|__fixtures__|__mocks__|integration|e2e)\//u.test(filename) || /\.(?:test|spec|e2e|integration)\.[cm]?[jt]sx?$/u.test(filename);
1853
- const framework = context.sourceCode.ast.body.some((statement) => statement.type === AST_NODE_TYPES16.ImportDeclaration && statement.importKind !== "type" && ["vitest", "@jest/globals", "@playwright/test", "bun:test", "node:test"].includes(statement.source.value));
1852
+ const unambiguous = /(?:^|\/)(?:tests?|__tests__|fixtures|__fixtures__|__mocks__)\//u.test(filename) || /\.(?:test|spec|e2e|integration)\.[cm]?[jt]sx?$/u.test(filename);
1853
+ const framework = context.sourceCode.ast.body.some((statement) => statement.type === AST_NODE_TYPES16.ImportDeclaration && statement.importKind !== "type" && (statement.specifiers.length === 0 || statement.specifiers.some((specifier) => specifier.type !== AST_NODE_TYPES16.ImportSpecifier || specifier.importKind !== "type")) && ["vitest", "@jest/globals", "@playwright/test", "bun:test", "node:test"].includes(statement.source.value));
1854
1854
  if (!unambiguous && !framework) return {};
1855
1855
  return {
1856
1856
  Program() {
@@ -3853,7 +3853,7 @@ function isSearchParamReceiver(call, services) {
3853
3853
  // package.json
3854
3854
  var package_default = {
3855
3855
  name: "@sarj/eslint-plugin",
3856
- version: "16.35.0",
3856
+ version: "16.35.1",
3857
3857
  packageManager: "npm@12.2.1",
3858
3858
  description: "Custom ESLint rules for hypermodern TypeScript / React / Next.js projects",
3859
3859
  type: "module",
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@sarj/eslint-plugin",
3
- "version": "16.35.0",
3
+ "version": "16.35.1",
4
4
  "packageManager": "npm@12.2.1",
5
5
  "description": "Custom ESLint rules for hypermodern TypeScript / React / Next.js projects",
6
6
  "type": "module",