@shivaedev/quality 0.69.4 → 0.70.0
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/CHANGELOG.md +20 -0
- package/README.md +9 -9
- package/dist/adapters/biome/browserDiagnostic.d.ts.map +1 -1
- package/dist/adapters/biome/browserDiagnostic.js +1 -1
- package/dist/adapters/biome/browserDiagnostic.js.map +1 -1
- package/dist/adapters/biome/configs.d.ts.map +1 -1
- package/dist/adapters/biome/configs.js +1 -1
- package/dist/adapters/biome/configs.js.map +1 -1
- package/dist/adapters/biome/pluginContract.d.ts +3 -0
- package/dist/adapters/biome/pluginContract.d.ts.map +1 -0
- package/dist/adapters/biome/pluginContract.js +35 -0
- package/dist/adapters/biome/pluginContract.js.map +1 -0
- package/dist/adapters/biome/presetConfig.d.ts.map +1 -1
- package/dist/adapters/biome/presetConfig.js +2 -2
- package/dist/adapters/biome/presetConfig.js.map +1 -1
- package/dist/adapters/biome/relocateConfig.js +1 -1
- package/dist/adapters/biome/relocateConfig.js.map +1 -1
- package/dist/adapters/biome/toolContractDefaults.d.ts +18 -0
- package/dist/adapters/biome/toolContractDefaults.d.ts.map +1 -0
- package/dist/adapters/biome/toolContractDefaults.js +28 -0
- package/dist/adapters/biome/toolContractDefaults.js.map +1 -0
- package/dist/adapters/biome/withExceptionConfig.js +2 -2
- package/dist/adapters/biome/withExceptionConfig.js.map +1 -1
- package/dist/adapters/bodyReferences.d.ts +1 -1
- package/dist/adapters/bodyReferences.d.ts.map +1 -1
- package/dist/adapters/bodyReferences.js +1 -1
- package/dist/adapters/bodyReferences.js.map +1 -1
- package/dist/adapters/buildEntryPaths.d.ts +2 -1
- package/dist/adapters/buildEntryPaths.d.ts.map +1 -1
- package/dist/adapters/buildEntryPaths.js +8 -5
- package/dist/adapters/buildEntryPaths.js.map +1 -1
- package/dist/adapters/buildEntryValue.d.ts +2 -1
- package/dist/adapters/buildEntryValue.d.ts.map +1 -1
- package/dist/adapters/buildEntryValue.js +11 -5
- package/dist/adapters/buildEntryValue.js.map +1 -1
- package/dist/adapters/buildHelper.d.ts +7 -0
- package/dist/adapters/buildHelper.d.ts.map +1 -0
- package/dist/adapters/buildHelper.js +55 -0
- package/dist/adapters/buildHelper.js.map +1 -0
- package/dist/adapters/bundlerEntries.d.ts +2 -1
- package/dist/adapters/bundlerEntries.d.ts.map +1 -1
- package/dist/adapters/bundlerEntries.js +30 -16
- package/dist/adapters/bundlerEntries.js.map +1 -1
- package/dist/adapters/bundlerSources.d.ts +5 -0
- package/dist/adapters/bundlerSources.d.ts.map +1 -0
- package/dist/adapters/bundlerSources.js +55 -0
- package/dist/adapters/bundlerSources.js.map +1 -0
- package/dist/adapters/changeKeyFindings.d.ts.map +1 -1
- package/dist/adapters/changeKeyFindings.js +1 -1
- package/dist/adapters/changeKeyFindings.js.map +1 -1
- package/dist/adapters/composedContext.d.ts +1 -1
- package/dist/adapters/composedContext.d.ts.map +1 -1
- package/dist/adapters/composedContext.js +37 -16
- package/dist/adapters/composedContext.js.map +1 -1
- package/dist/adapters/databaseUrlFindings.d.ts.map +1 -1
- package/dist/adapters/databaseUrlFindings.js +2 -2
- package/dist/adapters/databaseUrlFindings.js.map +1 -1
- package/dist/adapters/engineEscapes.js +2 -2
- package/dist/adapters/engineEscapes.js.map +1 -1
- package/dist/adapters/foreignResources.d.ts.map +1 -1
- package/dist/adapters/foreignResources.js +6 -0
- package/dist/adapters/foreignResources.js.map +1 -1
- package/dist/adapters/import-compiler/service.js +3 -3
- package/dist/adapters/import-compiler/service.js.map +1 -1
- package/dist/adapters/imports/departures.d.ts.map +1 -1
- package/dist/adapters/imports/departures.js +2 -24
- package/dist/adapters/imports/departures.js.map +1 -1
- package/dist/adapters/imports/fakeTargets.d.ts.map +1 -1
- package/dist/adapters/imports/fakeTargets.js +2 -2
- package/dist/adapters/imports/fakeTargets.js.map +1 -1
- package/dist/adapters/imports/graph.d.ts.map +1 -1
- package/dist/adapters/imports/graph.js +2 -2
- package/dist/adapters/imports/graph.js.map +1 -1
- package/dist/adapters/imports/resolve.d.ts +1 -1
- package/dist/adapters/imports/resolve.d.ts.map +1 -1
- package/dist/adapters/imports/resolve.js +14 -1
- package/dist/adapters/imports/resolve.js.map +1 -1
- package/dist/adapters/knip/configuration.d.ts.map +1 -1
- package/dist/adapters/knip/configuration.js +5 -3
- package/dist/adapters/knip/configuration.js.map +1 -1
- package/dist/adapters/knip/entryPointFindings.js +1 -1
- package/dist/adapters/knip/entryPointFindings.js.map +1 -1
- package/dist/adapters/knip/report.d.ts.map +1 -1
- package/dist/adapters/knip/report.js +1 -1
- package/dist/adapters/knip/report.js.map +1 -1
- package/dist/adapters/knip/run.d.ts.map +1 -1
- package/dist/adapters/knip/run.js +5 -5
- package/dist/adapters/knip/run.js.map +1 -1
- package/dist/adapters/moduleResolver.d.ts +3 -0
- package/dist/adapters/moduleResolver.d.ts.map +1 -0
- package/dist/adapters/moduleResolver.js +22 -0
- package/dist/adapters/moduleResolver.js.map +1 -0
- package/dist/adapters/nativeTransactionFindings.d.ts.map +1 -1
- package/dist/adapters/nativeTransactionFindings.js +1 -1
- package/dist/adapters/nativeTransactionFindings.js.map +1 -1
- package/dist/adapters/positiveRefusalFindings.d.ts.map +1 -1
- package/dist/adapters/positiveRefusalFindings.js +1 -1
- package/dist/adapters/positiveRefusalFindings.js.map +1 -1
- package/dist/adapters/queueReadoutFindings.d.ts.map +1 -1
- package/dist/adapters/queueReadoutFindings.js +3 -3
- package/dist/adapters/queueReadoutFindings.js.map +1 -1
- package/dist/adapters/reachableBuildEntries.d.ts.map +1 -1
- package/dist/adapters/reachableBuildEntries.js +7 -6
- package/dist/adapters/reachableBuildEntries.js.map +1 -1
- package/dist/adapters/reactComponent.d.ts +4 -0
- package/dist/adapters/reactComponent.d.ts.map +1 -0
- package/dist/adapters/reactComponent.js +61 -0
- package/dist/adapters/reactComponent.js.map +1 -0
- package/dist/adapters/rule.d.ts +1 -1
- package/dist/adapters/rule.d.ts.map +1 -1
- package/dist/adapters/rule.js +1 -1
- package/dist/adapters/rule.js.map +1 -1
- package/dist/adapters/serviceAccess.d.ts +1 -1
- package/dist/adapters/serviceAccess.d.ts.map +1 -1
- package/dist/adapters/serviceStateProblems.d.ts.map +1 -1
- package/dist/adapters/serviceStateProblems.js +2 -1
- package/dist/adapters/serviceStateProblems.js.map +1 -1
- package/dist/adapters/spawnedEntries.d.ts.map +1 -1
- package/dist/adapters/spawnedEntries.js +3 -3
- package/dist/adapters/spawnedEntries.js.map +1 -1
- package/dist/adapters/specReaderSources.d.ts.map +1 -1
- package/dist/adapters/specReaderSources.js +1 -1
- package/dist/adapters/specReaderSources.js.map +1 -1
- package/dist/adapters/testProjects.js +1 -1
- package/dist/adapters/testProjects.js.map +1 -1
- package/dist/adapters/units/runtime.d.ts.map +1 -1
- package/dist/adapters/units/runtime.js +2 -2
- package/dist/adapters/units/runtime.js.map +1 -1
- package/dist/adapters/units/runtimeOrigins.d.ts +1 -1
- package/dist/adapters/units/runtimeOrigins.d.ts.map +1 -1
- package/dist/adapters/units/runtimeOrigins.js +1 -1
- package/dist/adapters/units/runtimeOrigins.js.map +1 -1
- package/dist/adapters/units/runtimeUse.d.ts +1 -1
- package/dist/adapters/units/runtimeUse.d.ts.map +1 -1
- package/dist/adapters/units/runtimeUse.js +1 -1
- package/dist/adapters/units/runtimeUse.js.map +1 -1
- package/dist/adapters/vitestContractPaths.d.ts +2 -0
- package/dist/adapters/vitestContractPaths.d.ts.map +1 -0
- package/dist/adapters/vitestContractPaths.js +24 -0
- package/dist/adapters/vitestContractPaths.js.map +1 -0
- package/dist/baseline/compare.d.ts +1 -1
- package/dist/baseline/compare.d.ts.map +1 -1
- package/dist/baseline/compare.js.map +1 -1
- package/dist/baseline/legacy.d.ts +1 -1
- package/dist/baseline/legacy.d.ts.map +1 -1
- package/dist/baseline/legacy.js +1 -1
- package/dist/baseline/legacy.js.map +1 -1
- package/dist/baseline/looseStagedEntries.d.ts +1 -1
- package/dist/baseline/looseStagedEntries.d.ts.map +1 -1
- package/dist/baseline/looseStagedEntries.js +3 -3
- package/dist/baseline/looseStagedEntries.js.map +1 -1
- package/dist/baseline/rewrite.d.ts +1 -1
- package/dist/baseline/rewrite.d.ts.map +1 -1
- package/dist/baseline/rewrite.js +1 -1
- package/dist/baseline/rewrite.js.map +1 -1
- package/dist/baseline/update.d.ts +1 -1
- package/dist/baseline/update.d.ts.map +1 -1
- package/dist/baseline/update.js +1 -1
- package/dist/baseline/update.js.map +1 -1
- package/dist/biome/nativeEffectCall.d.ts +1 -1
- package/dist/biome/nativeEffectCall.d.ts.map +1 -1
- package/dist/biome/recognizeDiagnostics.d.ts +2 -2
- package/dist/biome/recognizeDiagnostics.d.ts.map +1 -1
- package/dist/biome/recognizeDiagnostics.js +21 -7
- package/dist/biome/recognizeDiagnostics.js.map +1 -1
- package/dist/biome/report.d.ts.map +1 -1
- package/dist/biome/report.js +3 -2
- package/dist/biome/report.js.map +1 -1
- package/dist/biome/withoutEntryPointImports.d.ts.map +1 -1
- package/dist/biome/withoutEntryPointImports.js.map +1 -1
- package/dist/cli/args.js +2 -2
- package/dist/cli/args.js.map +1 -1
- package/dist/cli/fix.d.ts.map +1 -1
- package/dist/cli/fix.js +1 -1
- package/dist/cli/fix.js.map +1 -1
- package/dist/cli/program.d.ts.map +1 -1
- package/dist/cli/program.js +1 -1
- package/dist/cli/program.js.map +1 -1
- package/dist/cli/shrink.d.ts.map +1 -1
- package/dist/cli/shrink.js +1 -1
- package/dist/cli/shrink.js.map +1 -1
- package/dist/config/load.d.ts +1 -1
- package/dist/config/load.d.ts.map +1 -1
- package/dist/config/load.js +3 -3
- package/dist/config/load.js.map +1 -1
- package/dist/config/resolve.d.ts.map +1 -1
- package/dist/config/resolve.js.map +1 -1
- package/dist/decoded.d.ts +1 -1
- package/dist/decoded.d.ts.map +1 -1
- package/dist/decoded.js +1 -1
- package/dist/decoded.js.map +1 -1
- package/dist/docs/documentedImports.js +1 -1
- package/dist/docs/documentedImports.js.map +1 -1
- package/dist/docs/headingAnchors.d.ts +1 -1
- package/dist/docs/headingAnchors.d.ts.map +1 -1
- package/dist/docs/importFindings.d.ts.map +1 -1
- package/dist/docs/importFindings.js +3 -3
- package/dist/docs/importFindings.js.map +1 -1
- package/dist/docs/linkFindings.d.ts +2 -2
- package/dist/docs/linkFindings.d.ts.map +1 -1
- package/dist/docs/linkFindings.js +2 -2
- package/dist/docs/linkFindings.js.map +1 -1
- package/dist/docs/markdownLinks.d.ts +1 -1
- package/dist/docs/markdownLinks.d.ts.map +1 -1
- package/dist/docs/markdownLinks.js +1 -1
- package/dist/docs/markdownLinks.js.map +1 -1
- package/dist/engine/evaluate.d.ts +1 -1
- package/dist/engine/evaluate.d.ts.map +1 -1
- package/dist/engine/evaluate.js +1 -1
- package/dist/engine/evaluate.js.map +1 -1
- package/dist/engine/runRules.d.ts +1 -1
- package/dist/engine/runRules.d.ts.map +1 -1
- package/dist/engine/runRules.js.map +1 -1
- package/dist/engine/session.d.ts +2 -2
- package/dist/engine/session.d.ts.map +1 -1
- package/dist/engine/session.js +2 -2
- package/dist/engine/session.js.map +1 -1
- package/dist/exceptions/migrateConfig.d.ts +1 -1
- package/dist/exceptions/migrateConfig.d.ts.map +1 -1
- package/dist/exceptions/registryEntries.d.ts +2 -2
- package/dist/exceptions/registryEntries.d.ts.map +1 -1
- package/dist/git/base.js +1 -1
- package/dist/git/base.js.map +1 -1
- package/dist/git/history.js +1 -1
- package/dist/git/history.js.map +1 -1
- package/dist/hooks/forwarding.js +2 -2
- package/dist/hooks/forwarding.js.map +1 -1
- package/dist/hooks/install.d.ts +1 -1
- package/dist/hooks/install.d.ts.map +1 -1
- package/dist/hooks/install.js +5 -5
- package/dist/hooks/install.js.map +1 -1
- package/dist/hooks/setup.d.ts +1 -1
- package/dist/hooks/setup.d.ts.map +1 -1
- package/dist/hooks/setup.js +1 -1
- package/dist/hooks/setup.js.map +1 -1
- package/dist/hooks/shim.d.ts +1 -1
- package/dist/hooks/shim.d.ts.map +1 -1
- package/dist/hooks/shim.js +1 -1
- package/dist/hooks/shim.js.map +1 -1
- package/dist/hooks/status.d.ts +1 -1
- package/dist/hooks/status.d.ts.map +1 -1
- package/dist/hooks/status.js +3 -3
- package/dist/hooks/status.js.map +1 -1
- package/dist/hooks/uninstall.js +3 -3
- package/dist/hooks/uninstall.js.map +1 -1
- package/dist/imports/adminEvidence.d.ts.map +1 -1
- package/dist/imports/adminEvidence.js +1 -1
- package/dist/imports/adminEvidence.js.map +1 -1
- package/dist/imports/adminFindings.d.ts +1 -1
- package/dist/imports/adminFindings.d.ts.map +1 -1
- package/dist/imports/adminFindings.js +1 -1
- package/dist/imports/adminFindings.js.map +1 -1
- package/dist/imports/browserGlobals.d.ts.map +1 -1
- package/dist/imports/browserGlobals.js +1 -1
- package/dist/imports/browserGlobals.js.map +1 -1
- package/dist/imports/classifyRuntime.d.ts +2 -2
- package/dist/imports/classifyRuntime.d.ts.map +1 -1
- package/dist/imports/classifyRuntime.js +2 -2
- package/dist/imports/classifyRuntime.js.map +1 -1
- package/dist/imports/departures.d.ts +1 -1
- package/dist/imports/departures.d.ts.map +1 -1
- package/dist/imports/departures.js +1 -1
- package/dist/imports/departures.js.map +1 -1
- package/dist/imports/extract.d.ts.map +1 -1
- package/dist/imports/extract.js +3 -15
- package/dist/imports/extract.js.map +1 -1
- package/dist/imports/fences/check.d.ts +1 -1
- package/dist/imports/fences/check.d.ts.map +1 -1
- package/dist/imports/fences/check.js +2 -2
- package/dist/imports/fences/check.js.map +1 -1
- package/dist/imports/fences/compilePolicy.d.ts +3 -3
- package/dist/imports/fences/compilePolicy.d.ts.map +1 -1
- package/dist/imports/fences/compilePolicy.js +1 -1
- package/dist/imports/fences/compilePolicy.js.map +1 -1
- package/dist/imports/fences/declarations.d.ts +1 -1
- package/dist/imports/fences/declarations.d.ts.map +1 -1
- package/dist/imports/fences/discover.d.ts +1 -1
- package/dist/imports/fences/discover.d.ts.map +1 -1
- package/dist/imports/fences/discover.js +1 -1
- package/dist/imports/fences/discover.js.map +1 -1
- package/dist/imports/fences/evaluate.d.ts +2 -2
- package/dist/imports/fences/evaluate.d.ts.map +1 -1
- package/dist/imports/fences/evaluate.js +3 -3
- package/dist/imports/fences/evaluate.js.map +1 -1
- package/dist/imports/fences/match.d.ts +1 -1
- package/dist/imports/fences/match.d.ts.map +1 -1
- package/dist/imports/fences/match.js.map +1 -1
- package/dist/imports/fences/reach.d.ts +1 -1
- package/dist/imports/fences/reach.d.ts.map +1 -1
- package/dist/imports/fences/selectors.d.ts +1 -1
- package/dist/imports/fences/selectors.d.ts.map +1 -1
- package/dist/imports/fences/vocabulary.d.ts +2 -2
- package/dist/imports/fences/vocabulary.d.ts.map +1 -1
- package/dist/imports/fences/vocabulary.js +1 -1
- package/dist/imports/fences/vocabulary.js.map +1 -1
- package/dist/imports/graph.d.ts +3 -3
- package/dist/imports/graph.d.ts.map +1 -1
- package/dist/imports/graph.js +1 -1
- package/dist/imports/graph.js.map +1 -1
- package/dist/imports/nodePlatformBarrels.d.ts.map +1 -1
- package/dist/imports/nodePlatformBarrels.js +1 -1
- package/dist/imports/nodePlatformBarrels.js.map +1 -1
- package/dist/imports/runtime.d.ts +1 -1
- package/dist/imports/runtime.d.ts.map +1 -1
- package/dist/imports/runtime.js +1 -1
- package/dist/imports/runtime.js.map +1 -1
- package/dist/imports/testComposition.d.ts +2 -2
- package/dist/imports/testComposition.d.ts.map +1 -1
- package/dist/imports/testComposition.js +1 -1
- package/dist/imports/testComposition.js.map +1 -1
- package/dist/imports/withoutGenerated.d.ts +2 -2
- package/dist/imports/withoutGenerated.d.ts.map +1 -1
- package/dist/imports/withoutGenerated.js.map +1 -1
- package/dist/imports/workspace.d.ts.map +1 -1
- package/dist/imports/workspace.js +2 -2
- package/dist/imports/workspace.js.map +1 -1
- package/dist/inventory/collect.d.ts +1 -1
- package/dist/inventory/collect.d.ts.map +1 -1
- package/dist/inventory/collect.js +6 -6
- package/dist/inventory/collect.js.map +1 -1
- package/dist/inventory/routeFiles.d.ts +1 -1
- package/dist/inventory/routeFiles.d.ts.map +1 -1
- package/dist/inventory/routeFiles.js +3 -3
- package/dist/inventory/routeFiles.js.map +1 -1
- package/dist/inventory/walk.d.ts +2 -2
- package/dist/inventory/walk.d.ts.map +1 -1
- package/dist/inventory/walk.js +3 -3
- package/dist/inventory/walk.js.map +1 -1
- package/dist/naming/developmentCode.d.ts +4 -0
- package/dist/naming/developmentCode.d.ts.map +1 -0
- package/dist/naming/developmentCode.js +16 -0
- package/dist/naming/developmentCode.js.map +1 -0
- package/dist/naming/isMigrationFile.js +1 -1
- package/dist/naming/isMigrationFile.js.map +1 -1
- package/dist/naming/nativeNames.js +1 -1
- package/dist/naming/nativeNames.js.map +1 -1
- package/dist/naming/testCode.d.ts.map +1 -1
- package/dist/naming/testCode.js +5 -3
- package/dist/naming/testCode.js.map +1 -1
- package/dist/report/render.js +2 -2
- package/dist/report/render.js.map +1 -1
- package/dist/report/staleSections.js +1 -1
- package/dist/report/staleSections.js.map +1 -1
- package/dist/rules/builtIn.js +12 -12
- package/dist/rules/builtIn.js.map +1 -1
- package/dist/rules/comments/definePattern.js +2 -2
- package/dist/rules/comments/definePattern.js.map +1 -1
- package/dist/rules/comments/kinds.d.ts +1 -1
- package/dist/rules/comments/kinds.d.ts.map +1 -1
- package/dist/rules/comments/kinds.js.map +1 -1
- package/dist/rules/comments/maxPerFile.js +2 -2
- package/dist/rules/comments/maxPerFile.js.map +1 -1
- package/dist/rules/comments/noBanner.js +1 -1
- package/dist/rules/comments/noBanner.js.map +1 -1
- package/dist/rules/comments/noEnvironmentPragma.js +1 -1
- package/dist/rules/comments/noEnvironmentPragma.js.map +1 -1
- package/dist/rules/comments/noJsdoc.js +2 -2
- package/dist/rules/comments/noJsdoc.js.map +1 -1
- package/dist/rules/comments/noLineReference.js +1 -1
- package/dist/rules/comments/noLineReference.js.map +1 -1
- package/dist/rules/comments/noPrReference.js +1 -1
- package/dist/rules/comments/noPrReference.js.map +1 -1
- package/dist/rules/comments/noTodo.js +1 -1
- package/dist/rules/comments/noTodo.js.map +1 -1
- package/dist/rules/effect/failureFindings.js +2 -2
- package/dist/rules/effect/failureFindings.js.map +1 -1
- package/dist/rules/effect/failureHonesty.js +2 -2
- package/dist/rules/effect/failureHonesty.js.map +1 -1
- package/dist/rules/effect/failureOperations.js +1 -1
- package/dist/rules/effect/failureOperations.js.map +1 -1
- package/dist/rules/effect/serviceFindings.d.ts.map +1 -1
- package/dist/rules/effect/serviceFindings.js +4 -0
- package/dist/rules/effect/serviceFindings.js.map +1 -1
- package/dist/rules/effect/serviceParameters.js +1 -1
- package/dist/rules/effect/serviceParameters.js.map +1 -1
- package/dist/rules/effect/serviceTypes.d.ts.map +1 -1
- package/dist/rules/effect/serviceTypes.js +1 -0
- package/dist/rules/effect/serviceTypes.js.map +1 -1
- package/dist/rules/effect/successRecovery.js +1 -1
- package/dist/rules/effect/successRecovery.js.map +1 -1
- package/dist/rules/files/otherNames.js +1 -1
- package/dist/rules/files/otherNames.js.map +1 -1
- package/dist/rules/files/stylesheetImporters.js +1 -1
- package/dist/rules/files/stylesheetImporters.js.map +1 -1
- package/dist/rules/imports/aliased.js +5 -5
- package/dist/rules/imports/aliased.js.map +1 -1
- package/dist/rules/imports/manifest.d.ts.map +1 -1
- package/dist/rules/imports/manifest.js +7 -2
- package/dist/rules/imports/manifest.js.map +1 -1
- package/dist/rules/imports/noTestCode.d.ts.map +1 -1
- package/dist/rules/imports/noTestCode.js +4 -2
- package/dist/rules/imports/noTestCode.js.map +1 -1
- package/dist/rules/manifestsDependencyPins.d.ts.map +1 -1
- package/dist/rules/manifestsDependencyPins.js +2 -3
- package/dist/rules/manifestsDependencyPins.js.map +1 -1
- package/dist/rules/noBarrel.js +2 -2
- package/dist/rules/noBarrel.js.map +1 -1
- package/dist/rules/react/jsxConditionals.js +1 -1
- package/dist/rules/react/jsxConditionals.js.map +1 -1
- package/dist/rules/secondNames.js +1 -1
- package/dist/rules/secondNames.js.map +1 -1
- package/dist/rules/stories/adapterOnlyFakes.js +1 -1
- package/dist/rules/stories/adapterOnlyFakes.js.map +1 -1
- package/dist/rules/stories/adapters/authTables.d.ts.map +1 -1
- package/dist/rules/stories/adapters/authTables.js +1 -1
- package/dist/rules/stories/adapters/authTables.js.map +1 -1
- package/dist/rules/stories/adapters/realTime.d.ts.map +1 -1
- package/dist/rules/stories/adapters/realTime.js +1 -1
- package/dist/rules/stories/adapters/realTime.js.map +1 -1
- package/dist/rules/stories/adapters/sqlTables.js +1 -1
- package/dist/rules/stories/adapters/sqlTables.js.map +1 -1
- package/dist/rules/stories/authSql.js +2 -2
- package/dist/rules/stories/authSql.js.map +1 -1
- package/dist/rules/stories/domainOutcomes.js +4 -4
- package/dist/rules/stories/domainOutcomes.js.map +1 -1
- package/dist/rules/stories/engine.js +4 -4
- package/dist/rules/stories/engine.js.map +1 -1
- package/dist/rules/stories/fakeImplementation.js +1 -1
- package/dist/rules/stories/fakeImplementation.js.map +1 -1
- package/dist/rules/stories/fakeReplacements.js +2 -2
- package/dist/rules/stories/fakeReplacements.js.map +1 -1
- package/dist/rules/stories/globalRetries.js +3 -3
- package/dist/rules/stories/globalRetries.js.map +1 -1
- package/dist/rules/stories/groupedOutcomes.js +3 -3
- package/dist/rules/stories/groupedOutcomes.js.map +1 -1
- package/dist/rules/stories/httpStatus.js +2 -2
- package/dist/rules/stories/httpStatus.js.map +1 -1
- package/dist/rules/stories/namedValues.js +2 -2
- package/dist/rules/stories/namedValues.js.map +1 -1
- package/dist/rules/stories/noExpect.js +2 -2
- package/dist/rules/stories/noExpect.js.map +1 -1
- package/dist/rules/stories/noLimitImports.js +2 -2
- package/dist/rules/stories/noLimitImports.js.map +1 -1
- package/dist/rules/stories/origins.d.ts +1 -1
- package/dist/rules/stories/origins.d.ts.map +1 -1
- package/dist/rules/stories/origins.js +4 -4
- package/dist/rules/stories/origins.js.map +1 -1
- package/dist/rules/stories/positiveRefusals.js +2 -2
- package/dist/rules/stories/positiveRefusals.js.map +1 -1
- package/dist/rules/stories/queueSql.js +1 -1
- package/dist/rules/stories/queueSql.js.map +1 -1
- package/dist/rules/stories/registersTests.js +1 -1
- package/dist/rules/stories/registersTests.js.map +1 -1
- package/dist/rules/stories/retryOption.js +1 -1
- package/dist/rules/stories/retryOption.js.map +1 -1
- package/dist/rules/stories/setup.js +1 -1
- package/dist/rules/stories/setup.js.map +1 -1
- package/dist/rules/stories/sources.js +2 -2
- package/dist/rules/stories/sources.js.map +1 -1
- package/dist/rules/stories/specHelpers.js +2 -2
- package/dist/rules/stories/specHelpers.js.map +1 -1
- package/dist/rules/stories/specs.js +3 -3
- package/dist/rules/stories/specs.js.map +1 -1
- package/dist/rules/stories/sqlText.js +1 -1
- package/dist/rules/stories/sqlText.js.map +1 -1
- package/dist/rules/stories/unitTests.js +3 -3
- package/dist/rules/stories/unitTests.js.map +1 -1
- package/dist/rules/stories/waitOnEvents.js +3 -3
- package/dist/rules/stories/waitOnEvents.js.map +1 -1
- package/dist/rules/suppressions/biome/ConsumerDeclaration.js +1 -1
- package/dist/rules/suppressions/biome/ConsumerDeclaration.js.map +1 -1
- package/dist/rules/suppressions/biome/weakenings.js +2 -2
- package/dist/rules/suppressions/biome/weakenings.js.map +1 -1
- package/dist/rules/suppressions/noDoubleCast.js +2 -2
- package/dist/rules/suppressions/noDoubleCast.js.map +1 -1
- package/dist/rules/suppressions/noInline.js +2 -2
- package/dist/rules/suppressions/noInline.js.map +1 -1
- package/dist/testing/adapters/hookRepository.d.ts +2 -2
- package/dist/testing/adapters/hookRepository.d.ts.map +1 -1
- package/dist/testing/adapters/hookRepository.js +5 -5
- package/dist/testing/adapters/hookRepository.js.map +1 -1
- package/dist/testing/adapters/packageExports.d.ts +1 -1
- package/dist/testing/adapters/packageExports.d.ts.map +1 -1
- package/dist/testing/adapters/qualityTree.d.ts +1 -1
- package/dist/testing/adapters/qualityTree.d.ts.map +1 -1
- package/dist/testing/adapters/qualityTree.js +1 -1
- package/dist/testing/adapters/qualityTree.js.map +1 -1
- package/dist/testing/adapters/storySpecFiles.d.ts +1 -1
- package/dist/testing/adapters/storySpecFiles.d.ts.map +1 -1
- package/dist/testing/adapters/writePackageExports.js +1 -1
- package/dist/testing/adapters/writePackageExports.js.map +1 -1
- package/package.json +1 -1
- package/src/adapters/biome/browserDiagnostic.ts +1 -1
- package/src/adapters/biome/configs.ts +1 -1
- package/src/adapters/biome/pluginContract.ts +42 -0
- package/src/adapters/biome/presetConfig.ts +2 -2
- package/src/adapters/biome/relocateConfig.ts +1 -1
- package/src/adapters/biome/toolContractDefaults.ts +31 -0
- package/src/adapters/biome/withExceptionConfig.ts +2 -2
- package/src/adapters/bodyReferences.ts +1 -1
- package/src/adapters/buildEntryPaths.ts +14 -5
- package/src/adapters/buildEntryValue.ts +13 -5
- package/src/adapters/buildHelper.ts +61 -0
- package/src/adapters/bundlerEntries.ts +40 -16
- package/src/adapters/bundlerSources.ts +60 -0
- package/src/adapters/changeKeyFindings.ts +1 -1
- package/src/adapters/composedContext.ts +42 -18
- package/src/adapters/databaseUrlFindings.ts +2 -2
- package/src/adapters/engineEscapes.ts +3 -3
- package/src/adapters/foreignResources.ts +6 -0
- package/src/adapters/import-compiler/service.ts +3 -3
- package/src/adapters/imports/departures.ts +2 -29
- package/src/adapters/imports/fakeTargets.ts +2 -2
- package/src/adapters/imports/graph.ts +2 -2
- package/src/adapters/imports/resolve.ts +14 -1
- package/src/adapters/knip/configuration.ts +5 -3
- package/src/adapters/knip/entryPointFindings.ts +1 -1
- package/src/adapters/knip/report.ts +1 -1
- package/src/adapters/knip/run.ts +5 -5
- package/src/adapters/moduleResolver.ts +23 -0
- package/src/adapters/nativeTransactionFindings.ts +1 -1
- package/src/adapters/positiveRefusalFindings.ts +1 -1
- package/src/adapters/queueReadoutFindings.ts +3 -3
- package/src/adapters/reachableBuildEntries.ts +7 -6
- package/src/adapters/reactComponent.ts +72 -0
- package/src/adapters/rule.ts +1 -1
- package/src/adapters/serviceAccess.ts +1 -1
- package/src/adapters/serviceStateProblems.ts +2 -1
- package/src/adapters/spawnedEntries.ts +3 -3
- package/src/adapters/specReaderSources.ts +1 -1
- package/src/adapters/testProjects.ts +1 -1
- package/src/adapters/units/runtime.ts +2 -2
- package/src/adapters/units/runtimeOrigins.ts +1 -1
- package/src/adapters/units/runtimeUse.ts +1 -1
- package/src/adapters/vitestContractPaths.ts +25 -0
- package/src/baseline/compare.ts +1 -1
- package/src/baseline/legacy.ts +2 -2
- package/src/baseline/looseStagedEntries.ts +3 -3
- package/src/baseline/rewrite.ts +1 -1
- package/src/baseline/update.ts +2 -2
- package/src/biome/nativeEffectCall.ts +1 -1
- package/src/biome/recognizeDiagnostics.ts +29 -8
- package/src/biome/report.ts +3 -2
- package/src/biome/withoutEntryPointImports.ts +1 -1
- package/src/cli/args.ts +2 -2
- package/src/cli/fix.ts +1 -1
- package/src/cli/program.ts +1 -1
- package/src/cli/shrink.ts +1 -1
- package/src/config/load.ts +3 -3
- package/src/config/resolve.ts +1 -1
- package/src/decoded.ts +1 -1
- package/src/docs/documentedImports.ts +1 -1
- package/src/docs/headingAnchors.ts +1 -1
- package/src/docs/importFindings.ts +3 -3
- package/src/docs/linkFindings.ts +3 -3
- package/src/docs/markdownLinks.ts +1 -1
- package/src/engine/evaluate.ts +1 -1
- package/src/engine/runRules.ts +1 -1
- package/src/engine/session.ts +3 -3
- package/src/exceptions/migrateConfig.ts +1 -1
- package/src/exceptions/registryEntries.ts +2 -2
- package/src/git/base.ts +1 -1
- package/src/git/history.ts +1 -1
- package/src/hooks/forwarding.ts +2 -2
- package/src/hooks/install.ts +5 -5
- package/src/hooks/setup.ts +1 -1
- package/src/hooks/shim.ts +1 -1
- package/src/hooks/status.ts +3 -3
- package/src/hooks/uninstall.ts +3 -3
- package/src/imports/adminEvidence.ts +1 -1
- package/src/imports/adminFindings.ts +2 -2
- package/src/imports/browserGlobals.ts +1 -1
- package/src/imports/classifyRuntime.ts +3 -3
- package/src/imports/departures.ts +2 -2
- package/src/imports/extract.ts +3 -17
- package/src/imports/fences/check.ts +3 -3
- package/src/imports/fences/compilePolicy.ts +3 -3
- package/src/imports/fences/declarations.ts +1 -1
- package/src/imports/fences/discover.ts +2 -2
- package/src/imports/fences/evaluate.ts +4 -4
- package/src/imports/fences/match.ts +1 -1
- package/src/imports/fences/reach.ts +1 -1
- package/src/imports/fences/selectors.ts +1 -1
- package/src/imports/fences/vocabulary.ts +2 -2
- package/src/imports/graph.ts +3 -3
- package/src/imports/nodePlatformBarrels.ts +1 -1
- package/src/imports/runtime.ts +2 -2
- package/src/imports/testComposition.ts +2 -2
- package/src/imports/withoutGenerated.ts +1 -1
- package/src/imports/workspace.ts +2 -2
- package/src/inventory/collect.ts +6 -6
- package/src/inventory/routeFiles.ts +3 -3
- package/src/inventory/walk.ts +3 -3
- package/src/naming/developmentCode.ts +21 -0
- package/src/naming/isMigrationFile.ts +1 -1
- package/src/naming/nativeNames.ts +1 -1
- package/src/naming/testCode.ts +5 -3
- package/src/report/render.ts +2 -2
- package/src/report/staleSections.ts +1 -1
- package/src/rules/builtIn.ts +12 -12
- package/src/rules/comments/definePattern.ts +2 -2
- package/src/rules/comments/kinds.ts +1 -1
- package/src/rules/comments/maxPerFile.ts +2 -2
- package/src/rules/comments/noBanner.ts +1 -1
- package/src/rules/comments/noEnvironmentPragma.ts +1 -1
- package/src/rules/comments/noJsdoc.ts +2 -2
- package/src/rules/comments/noLineReference.ts +1 -1
- package/src/rules/comments/noPrReference.ts +1 -1
- package/src/rules/comments/noTodo.ts +1 -1
- package/src/rules/effect/failureFindings.ts +2 -2
- package/src/rules/effect/failureHonesty.ts +2 -2
- package/src/rules/effect/failureOperations.ts +1 -1
- package/src/rules/effect/serviceFindings.ts +4 -0
- package/src/rules/effect/serviceParameters.ts +1 -1
- package/src/rules/effect/serviceTypes.ts +1 -0
- package/src/rules/effect/successRecovery.ts +1 -1
- package/src/rules/files/otherNames.ts +1 -1
- package/src/rules/files/stylesheetImporters.ts +1 -1
- package/src/rules/imports/aliased.ts +5 -5
- package/src/rules/imports/manifest.ts +7 -2
- package/src/rules/imports/noTestCode.ts +5 -2
- package/src/rules/manifestsDependencyPins.ts +2 -3
- package/src/rules/noBarrel.ts +2 -2
- package/src/rules/react/jsxConditionals.ts +1 -1
- package/src/rules/secondNames.ts +1 -1
- package/src/rules/stories/adapterOnlyFakes.ts +1 -1
- package/src/rules/stories/adapters/authTables.ts +1 -1
- package/src/rules/stories/adapters/realTime.ts +1 -1
- package/src/rules/stories/adapters/sqlTables.ts +1 -1
- package/src/rules/stories/authSql.ts +2 -2
- package/src/rules/stories/domainOutcomes.ts +4 -4
- package/src/rules/stories/engine.ts +4 -4
- package/src/rules/stories/fakeImplementation.ts +1 -1
- package/src/rules/stories/fakeReplacements.ts +2 -2
- package/src/rules/stories/globalRetries.ts +4 -4
- package/src/rules/stories/groupedOutcomes.ts +3 -3
- package/src/rules/stories/httpStatus.ts +2 -2
- package/src/rules/stories/namedValues.ts +2 -2
- package/src/rules/stories/noExpect.ts +2 -2
- package/src/rules/stories/noLimitImports.ts +2 -2
- package/src/rules/stories/origins.ts +4 -4
- package/src/rules/stories/positiveRefusals.ts +2 -2
- package/src/rules/stories/queueSql.ts +1 -1
- package/src/rules/stories/registersTests.ts +1 -1
- package/src/rules/stories/retryOption.ts +1 -1
- package/src/rules/stories/setup.ts +1 -1
- package/src/rules/stories/sources.ts +2 -2
- package/src/rules/stories/specHelpers.ts +2 -2
- package/src/rules/stories/specs.ts +3 -3
- package/src/rules/stories/sqlText.ts +1 -1
- package/src/rules/stories/unitTests.ts +3 -3
- package/src/rules/stories/waitOnEvents.ts +3 -3
- package/src/rules/suppressions/biome/ConsumerDeclaration.ts +1 -1
- package/src/rules/suppressions/biome/weakenings.ts +2 -2
- package/src/rules/suppressions/noDoubleCast.ts +2 -2
- package/src/rules/suppressions/noInline.ts +2 -2
- package/src/testing/adapters/hookRepository.ts +5 -9
- package/src/testing/adapters/packageExports.ts +1 -1
- package/src/testing/adapters/qualityTree.ts +1 -1
- package/src/testing/adapters/storySpecFiles.ts +1 -1
- package/src/testing/adapters/writePackageExports.ts +1 -1
|
@@ -7,7 +7,6 @@ import { defineRule, type Finding } from "#rule.ts";
|
|
|
7
7
|
const SECTIONS = ["dependencies", "devDependencies", "optionalDependencies", "peerDependencies"] as const;
|
|
8
8
|
const EXACT =
|
|
9
9
|
/^(?:npm:(?:@[^/\s]+\/)?[^@\s]+@)?(?:0|[1-9]\d*)\.(?:0|[1-9]\d*)\.(?:0|[1-9]\d*)(?:-[\dA-Za-z-]+(?:\.[\dA-Za-z-]+)*)?(?:\+[\dA-Za-z-]+(?:\.[\dA-Za-z-]+)*)?$/u;
|
|
10
|
-
const LOCAL = /^(?:workspace:|file:|link:)/u;
|
|
11
10
|
|
|
12
11
|
function dependencyFinding(
|
|
13
12
|
file: string,
|
|
@@ -16,7 +15,7 @@ function dependencyFinding(
|
|
|
16
15
|
version: string,
|
|
17
16
|
catalogs: ReturnType<typeof catalogEntries>,
|
|
18
17
|
): readonly Finding[] {
|
|
19
|
-
if (
|
|
18
|
+
if (version.startsWith("workspace:")) {
|
|
20
19
|
return [];
|
|
21
20
|
}
|
|
22
21
|
const catalog = version.startsWith("catalog:") ? version.slice("catalog:".length) : undefined;
|
|
@@ -29,7 +28,7 @@ function dependencyFinding(
|
|
|
29
28
|
: [
|
|
30
29
|
{
|
|
31
30
|
file,
|
|
32
|
-
message: `${section} entry "${name}: ${version}" must ${catalogs.present || catalog !== undefined ? 'use "catalog:" (or a named catalog) with an entry for this dependency in pnpm-workspace.yaml' : "pin an exact version, including for npm aliases"}.
|
|
31
|
+
message: `${section} entry "${name}: ${version}" must ${catalogs.present || catalog !== undefined ? 'use "catalog:" (or a named catalog) with an entry for this dependency in pnpm-workspace.yaml' : "pin an exact npm version, including for npm aliases"}. Use "workspace:" for workspace dependencies; replace "file:" and "link:" with npm versions or workspace/catalog references.`,
|
|
33
32
|
subject: `${section}.${name}`,
|
|
34
33
|
},
|
|
35
34
|
];
|
package/src/rules/noBarrel.ts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { posix } from "node:path";
|
|
2
2
|
import { defineRule, type Finding } from "#rule.ts";
|
|
3
|
-
import { parse } from "
|
|
4
|
-
import { secondNames } from "
|
|
3
|
+
import { parse } from "#rules/parse.ts";
|
|
4
|
+
import { secondNames } from "#rules/secondNames.ts";
|
|
5
5
|
|
|
6
6
|
const BARREL_FILE = /^index\.tsx?$/u;
|
|
7
7
|
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import ts from "typescript";
|
|
2
2
|
import { defineRule, type Finding } from "#rule.ts";
|
|
3
3
|
import { parse } from "#rules/parse.ts";
|
|
4
|
-
import { jsxChildDecision } from "
|
|
4
|
+
import { jsxChildDecision } from "#rules/react/jsxChildDecision.ts";
|
|
5
5
|
|
|
6
6
|
const REPAIR =
|
|
7
7
|
"Decide before the JSX with an if and early return, or a variable computed above the return; or extract a component that receives the data and returns null when it has nothing to show.";
|
package/src/rules/secondNames.ts
CHANGED
|
@@ -6,7 +6,7 @@ import { storyProgram } from "#adapters/storyProgram.ts";
|
|
|
6
6
|
import { importGraph } from "#imports/graph.ts";
|
|
7
7
|
import { isTestCode } from "#naming/testName.ts";
|
|
8
8
|
import { defineRule, type Finding } from "#rule.ts";
|
|
9
|
-
import { fakeReplacements } from "
|
|
9
|
+
import { fakeReplacements } from "#rules/stories/fakeReplacements.ts";
|
|
10
10
|
|
|
11
11
|
function internal(path: string): boolean {
|
|
12
12
|
return !path.split("/").includes("adapters");
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import ts from "typescript";
|
|
2
|
+
import { rejectingTimer } from "#rules/stories/adapters/failureDeadline.ts";
|
|
2
3
|
import type { ImportBinding } from "#rules/stories/importBindings.ts";
|
|
3
4
|
import { memberName, unwrapped } from "#rules/stories/syntax.ts";
|
|
4
|
-
import { rejectingTimer } from "./failureDeadline.ts";
|
|
5
5
|
|
|
6
6
|
const TIMERS = new Set(["setTimeout", "setInterval", "requestAnimationFrame"]);
|
|
7
7
|
const TIMER_MODULES = new Set(["node:timers", "timers", "node:timers/promises", "timers/promises"]);
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { sqlTokens, tableAt } from "
|
|
1
|
+
import { sqlTokens, tableAt } from "#rules/stories/adapters/sqlTokens.ts";
|
|
2
2
|
|
|
3
3
|
const TABLE_START = new Set(["from", "join", "update", "into", "table", "truncate", "references", "using"]);
|
|
4
4
|
const TABLE_END = new Set(["where", "group", "order", "having", "limit", "returning", "set", "values", "on", ";"]);
|
|
@@ -3,8 +3,8 @@ import { GlobDeclarations, globPatterns, validateGlobs } from "#config/globs.ts"
|
|
|
3
3
|
import { defineRule } from "#rule.ts";
|
|
4
4
|
import { authTables } from "#rules/stories/adapters/authTables.ts";
|
|
5
5
|
import { sqlTables } from "#rules/stories/adapters/sqlTables.ts";
|
|
6
|
-
import { matchesAny } from "
|
|
7
|
-
import { sqlTexts } from "
|
|
6
|
+
import { matchesAny } from "#rules/stories/matchesAny.ts";
|
|
7
|
+
import { sqlTexts } from "#rules/stories/sqlText.ts";
|
|
8
8
|
|
|
9
9
|
const AuthSqlOptions = Schema.Struct({
|
|
10
10
|
owners: GlobDeclarations,
|
|
@@ -3,10 +3,10 @@ import ts from "typescript";
|
|
|
3
3
|
import { importGraph } from "#imports/graph.ts";
|
|
4
4
|
import { defineRule } from "#rule.ts";
|
|
5
5
|
import { internalValue, shapeModule } from "#rules/stories/adapters/outcomeShapes.ts";
|
|
6
|
-
import { importBindings } from "
|
|
7
|
-
import { storyOrigins } from "
|
|
8
|
-
import { storySources } from "
|
|
9
|
-
import { findingAt, memberName, nodesWhere, unwrapped } from "
|
|
6
|
+
import { importBindings } from "#rules/stories/importBindings.ts";
|
|
7
|
+
import { storyOrigins } from "#rules/stories/origins.ts";
|
|
8
|
+
import { storySources } from "#rules/stories/sources.ts";
|
|
9
|
+
import { findingAt, memberName, nodesWhere, unwrapped } from "#rules/stories/syntax.ts";
|
|
10
10
|
|
|
11
11
|
const MESSAGE =
|
|
12
12
|
'Uses an Exit, Cause or Result value or reads an internal outcome tag in a story. Have the kit\'s verb or readout return the outcome in the domain\'s words, such as "unauthorized" or "rolled back", and expect that; build failing inputs in a kit trait.';
|
|
@@ -5,10 +5,10 @@ import { importGraph } from "#imports/graph.ts";
|
|
|
5
5
|
import { packageOf } from "#imports/workspace.ts";
|
|
6
6
|
import { testName } from "#naming/testName.ts";
|
|
7
7
|
import { defineRule } from "#rule.ts";
|
|
8
|
-
import { storyOrigins } from "
|
|
9
|
-
import { storyPrerequisites } from "
|
|
10
|
-
import { nodesWhere, unwrapped } from "
|
|
11
|
-
import { storyUsesInputs } from "
|
|
8
|
+
import { storyOrigins } from "#rules/stories/origins.ts";
|
|
9
|
+
import { storyPrerequisites } from "#rules/stories/prerequisites.ts";
|
|
10
|
+
import { nodesWhere, unwrapped } from "#rules/stories/syntax.ts";
|
|
11
|
+
import { storyUsesInputs } from "#rules/stories/usesInputs.ts";
|
|
12
12
|
|
|
13
13
|
function ignoresEngine(call: ts.CallExpression, checker: ts.TypeChecker): boolean {
|
|
14
14
|
const traits = call.arguments[1];
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import ts from "typescript";
|
|
2
2
|
import type { fakeReferences } from "#adapters/imports/fakeReferences.ts";
|
|
3
|
-
import { memberName, unwrapped } from "
|
|
3
|
+
import { memberName, unwrapped } from "#rules/stories/syntax.ts";
|
|
4
4
|
|
|
5
5
|
export function fakeImplementation(expression: ts.Expression, references: ReturnType<typeof fakeReferences>, seen = new Set<ts.Node>()): boolean {
|
|
6
6
|
const node = unwrapped(expression);
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import ts from "typescript";
|
|
2
2
|
import { fakeApi, type fakeReferences } from "#adapters/imports/fakeReferences.ts";
|
|
3
|
-
import { fakeImplementation } from "
|
|
4
|
-
import { memberName, unwrapped } from "
|
|
3
|
+
import { fakeImplementation } from "#rules/stories/fakeImplementation.ts";
|
|
4
|
+
import { memberName, unwrapped } from "#rules/stories/syntax.ts";
|
|
5
5
|
|
|
6
6
|
const REPLACEMENTS = new Set([
|
|
7
7
|
"mockImplementation",
|
|
@@ -2,10 +2,10 @@ import { Effect } from "effect";
|
|
|
2
2
|
import ts from "typescript";
|
|
3
3
|
import { importGraph } from "#imports/graph.ts";
|
|
4
4
|
import { defineRule } from "#rule.ts";
|
|
5
|
-
import type { Origin } from "
|
|
6
|
-
import { storyOrigins } from "
|
|
7
|
-
import { retryOption } from "
|
|
8
|
-
import { memberName, nodesWhere } from "
|
|
5
|
+
import type { Origin } from "#rules/stories/collectionOrigins.ts";
|
|
6
|
+
import { storyOrigins } from "#rules/stories/origins.ts";
|
|
7
|
+
import { retryOption } from "#rules/stories/retryOption.ts";
|
|
8
|
+
import { memberName, nodesWhere } from "#rules/stories/syntax.ts";
|
|
9
9
|
|
|
10
10
|
const BUILDERS = new Set(["each", "for", "extend", "runIf", "skipIf", "layer"]);
|
|
11
11
|
const MESSAGE =
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import { Effect } from "effect";
|
|
2
2
|
import ts from "typescript";
|
|
3
3
|
import { defineRule } from "#rule.ts";
|
|
4
|
-
import { importBindings } from "
|
|
5
|
-
import { storySources } from "
|
|
6
|
-
import { memberName, syntaxFindings, unwrapped } from "
|
|
4
|
+
import { importBindings } from "#rules/stories/importBindings.ts";
|
|
5
|
+
import { storySources } from "#rules/stories/sources.ts";
|
|
6
|
+
import { memberName, syntaxFindings, unwrapped } from "#rules/stories/syntax.ts";
|
|
7
7
|
|
|
8
8
|
const MESSAGE =
|
|
9
9
|
'Checks several outcomes with consecutive expect(yield* …) lines. Let the story\'s words lead: yield* outcomes([["label", () => readout(), expected], …]) from @shivaedev/test-story/server/outcomes.ts, one row per outcome. Keep a plain expect for a single outcome.';
|
|
@@ -4,8 +4,8 @@ import * as HttpStatus from "effect/http/HttpStatus";
|
|
|
4
4
|
import ts from "typescript";
|
|
5
5
|
import { GlobDeclarations, globPatterns, validateGlobs } from "#config/globs.ts";
|
|
6
6
|
import { defineRule } from "#rule.ts";
|
|
7
|
-
import { matchesAny } from "
|
|
8
|
-
import { memberName, nodesWhere, numericValue, syntaxFindings, unwrapped } from "
|
|
7
|
+
import { matchesAny } from "#rules/stories/matchesAny.ts";
|
|
8
|
+
import { memberName, nodesWhere, numericValue, syntaxFindings, unwrapped } from "#rules/stories/syntax.ts";
|
|
9
9
|
|
|
10
10
|
const MESSAGE =
|
|
11
11
|
"Branches on an HTTP error status outside the HTTP edge. Handle the typed domain error here and translate it to an HTTP status in the configured edge module.";
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { Effect } from "effect";
|
|
2
2
|
import ts from "typescript";
|
|
3
3
|
import { defineRule } from "#rule.ts";
|
|
4
|
-
import { storySources } from "
|
|
5
|
-
import { memberName, nodesWhere, numericValue, syntaxFindings, unwrapped } from "
|
|
4
|
+
import { storySources } from "#rules/stories/sources.ts";
|
|
5
|
+
import { memberName, nodesWhere, numericValue, syntaxFindings, unwrapped } from "#rules/stories/syntax.ts";
|
|
6
6
|
|
|
7
7
|
const MESSAGE =
|
|
8
8
|
'Passes a numeric literal or a matcher-only spec-local numeric const to toBe or toHaveLength. Assert the observed items, write the literal where accepted (zero or a process exitCode), or derive the value from the story\'s inputs. For HTTP statuses, import * as HttpStatus from "effect/http/HttpStatus" and use HttpStatus.fromLiteral("NotFound"), for example.';
|
|
@@ -3,8 +3,8 @@ import ts from "typescript";
|
|
|
3
3
|
import { importGraph } from "#imports/graph.ts";
|
|
4
4
|
import { isTestSupport } from "#naming/testName.ts";
|
|
5
5
|
import { defineRule } from "#rule.ts";
|
|
6
|
-
import { registersTests } from "
|
|
7
|
-
import { memberName, nodesWhere, syntaxFindings, unwrapped } from "
|
|
6
|
+
import { registersTests } from "#rules/stories/registersTests.ts";
|
|
7
|
+
import { memberName, nodesWhere, syntaxFindings, unwrapped } from "#rules/stories/syntax.ts";
|
|
8
8
|
|
|
9
9
|
const MESSAGE =
|
|
10
10
|
"Calls expect in test-support. Return the engine's observed state from the verb and put the expectation in the spec; throw if an action cannot run.";
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { Effect } from "effect";
|
|
2
2
|
import ts from "typescript";
|
|
3
3
|
import { defineRule } from "#rule.ts";
|
|
4
|
-
import { storySources } from "
|
|
5
|
-
import { memberName, nodesWhere, syntaxFindings, unwrapped } from "
|
|
4
|
+
import { storySources } from "#rules/stories/sources.ts";
|
|
5
|
+
import { memberName, nodesWhere, syntaxFindings, unwrapped } from "#rules/stories/syntax.ts";
|
|
6
6
|
|
|
7
7
|
const MESSAGE =
|
|
8
8
|
"Imports a MAX_* constant from a limits module. Tell a story about the observed behavior instead of asserting a copy of the implementation's cap.";
|
|
@@ -3,10 +3,10 @@ import ts from "typescript";
|
|
|
3
3
|
import { storyProgram } from "#adapters/storyProgram.ts";
|
|
4
4
|
import type { ImportGraph } from "#imports/graph.ts";
|
|
5
5
|
import type { RuleInputs } from "#rule.ts";
|
|
6
|
-
import { iterationOrigin, type Origin } from "
|
|
7
|
-
import { importFrom, importOrigin } from "
|
|
8
|
-
import { returnValues } from "
|
|
9
|
-
import { memberName } from "
|
|
6
|
+
import { iterationOrigin, type Origin } from "#rules/stories/collectionOrigins.ts";
|
|
7
|
+
import { importFrom, importOrigin } from "#rules/stories/importOrigin.ts";
|
|
8
|
+
import { returnValues } from "#rules/stories/returnValues.ts";
|
|
9
|
+
import { memberName } from "#rules/stories/syntax.ts";
|
|
10
10
|
|
|
11
11
|
export function storyOrigins(inputs: RuleInputs, graph: ImportGraph) {
|
|
12
12
|
const program = storyProgram(inputs, graph);
|
|
@@ -2,8 +2,8 @@ import { Effect } from "effect";
|
|
|
2
2
|
import { positiveRefusalFindings } from "#adapters/positiveRefusalFindings.ts";
|
|
3
3
|
import { importGraph } from "#imports/graph.ts";
|
|
4
4
|
import { defineRule } from "#rule.ts";
|
|
5
|
-
import { storyOrigins } from "
|
|
6
|
-
import { storySources } from "
|
|
5
|
+
import { storyOrigins } from "#rules/stories/origins.ts";
|
|
6
|
+
import { storySources } from "#rules/stories/sources.ts";
|
|
7
7
|
|
|
8
8
|
export const positiveRefusals = defineRule({
|
|
9
9
|
check: Effect.fn("Stories.check")(function* (inputs) {
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import ts from "typescript";
|
|
2
|
-
import { memberName, unwrapped } from "
|
|
2
|
+
import { memberName, unwrapped } from "#rules/stories/syntax.ts";
|
|
3
3
|
|
|
4
4
|
function vitestBindings(source: ts.SourceFile): ReadonlyMap<string, string> {
|
|
5
5
|
const names = new Map<string, string>();
|
|
@@ -2,7 +2,7 @@ import ts from "typescript";
|
|
|
2
2
|
import { isTestSupport, testName } from "#naming/testName.ts";
|
|
3
3
|
import { defineRule, type Finding, type SourceFile } from "#rule.ts";
|
|
4
4
|
import { parse } from "#rules/parse.ts";
|
|
5
|
-
import { fixtureWrites } from "
|
|
5
|
+
import { fixtureWrites } from "#rules/stories/fixtureWrites.ts";
|
|
6
6
|
|
|
7
7
|
const SETUP_HELPER = /^(?:seed|make|build|setup)(?![a-z])/u;
|
|
8
8
|
const STORY_KIT =
|
|
@@ -5,8 +5,8 @@ import { importGraph } from "#imports/graph.ts";
|
|
|
5
5
|
import { packageOf } from "#imports/workspace.ts";
|
|
6
6
|
import { isTestSupport, testName } from "#naming/testName.ts";
|
|
7
7
|
import type { RuleInputs } from "#rule.ts";
|
|
8
|
-
import { storyOrigins } from "
|
|
9
|
-
import { storyPrerequisites } from "
|
|
8
|
+
import { storyOrigins } from "#rules/stories/origins.ts";
|
|
9
|
+
import { storyPrerequisites } from "#rules/stories/prerequisites.ts";
|
|
10
10
|
|
|
11
11
|
export const storySources = Effect.fn("Stories.storySources")(function* (inputs: RuleInputs) {
|
|
12
12
|
const graph = yield* importGraph(inputs);
|
|
@@ -2,8 +2,8 @@ import { Effect } from "effect";
|
|
|
2
2
|
import { pureReader } from "#adapters/pureReader.ts";
|
|
3
3
|
import { specReaderSources } from "#adapters/specReaderSources.ts";
|
|
4
4
|
import { defineRule } from "#rule.ts";
|
|
5
|
-
import { storySources } from "
|
|
6
|
-
import { findingAt, topLevelHelpers } from "
|
|
5
|
+
import { storySources } from "#rules/stories/sources.ts";
|
|
6
|
+
import { findingAt, topLevelHelpers } from "#rules/stories/syntax.ts";
|
|
7
7
|
|
|
8
8
|
const MESSAGE =
|
|
9
9
|
"Declares a setup or action helper in a spec. Move the action into the story kit's verbs or the setup into its traits in test-support/.";
|
|
@@ -5,9 +5,9 @@ import { importGraph } from "#imports/graph.ts";
|
|
|
5
5
|
import { packageOf } from "#imports/workspace.ts";
|
|
6
6
|
import { testName } from "#naming/testName.ts";
|
|
7
7
|
import { defineRule } from "#rule.ts";
|
|
8
|
-
import { storyOrigins } from "
|
|
9
|
-
import { storyPrerequisites } from "
|
|
10
|
-
import { unitTests } from "
|
|
8
|
+
import { storyOrigins } from "#rules/stories/origins.ts";
|
|
9
|
+
import { storyPrerequisites } from "#rules/stories/prerequisites.ts";
|
|
10
|
+
import { unitTests } from "#rules/stories/unitTests.ts";
|
|
11
11
|
|
|
12
12
|
function namesTest(node: ts.Expression): boolean {
|
|
13
13
|
if (ts.isIdentifier(node)) {
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import ts from "typescript";
|
|
2
2
|
import type { RuleInputs } from "#rule.ts";
|
|
3
3
|
import { parse } from "#rules/parse.ts";
|
|
4
|
-
import { unwrapped } from "
|
|
4
|
+
import { unwrapped } from "#rules/stories/syntax.ts";
|
|
5
5
|
|
|
6
6
|
export interface SqlText {
|
|
7
7
|
readonly file: string;
|
|
@@ -4,10 +4,10 @@ import { packageNameOf } from "#imports/packageName.ts";
|
|
|
4
4
|
import { isTestSupport } from "#naming/testName.ts";
|
|
5
5
|
import type { Finding, SourceFile } from "#rule.ts";
|
|
6
6
|
import { parse } from "#rules/parse.ts";
|
|
7
|
+
import { engineOf } from "#rules/stories/engineOf.ts";
|
|
8
|
+
import { pureNetImport } from "#rules/stories/pureNetImport.ts";
|
|
9
|
+
import { type Stand, standIns } from "#rules/stories/unitSyntax.ts";
|
|
7
10
|
import { usesDom } from "#rules/test-names/usesDom.ts";
|
|
8
|
-
import { engineOf } from "./engineOf.ts";
|
|
9
|
-
import { pureNetImport } from "./pureNetImport.ts";
|
|
10
|
-
import { type Stand, standIns } from "./unitSyntax.ts";
|
|
11
11
|
|
|
12
12
|
const RELATIVE = /^[./#]/u;
|
|
13
13
|
|
|
@@ -5,9 +5,9 @@ import { defineRule } from "#rule.ts";
|
|
|
5
5
|
import { eventConsumption, repeatedEventConsumption } from "#rules/stories/adapters/eventConsumption.ts";
|
|
6
6
|
import { failingSleep } from "#rules/stories/adapters/failureDeadline.ts";
|
|
7
7
|
import { realTime } from "#rules/stories/adapters/realTime.ts";
|
|
8
|
-
import { bindsModule, type ImportBinding, importBindings } from "
|
|
9
|
-
import { storyWaitSources } from "
|
|
10
|
-
import { memberName, syntaxFindings, unwrapped } from "
|
|
8
|
+
import { bindsModule, type ImportBinding, importBindings } from "#rules/stories/importBindings.ts";
|
|
9
|
+
import { storyWaitSources } from "#rules/stories/sources.ts";
|
|
10
|
+
import { memberName, syntaxFindings, unwrapped } from "#rules/stories/syntax.ts";
|
|
11
11
|
|
|
12
12
|
const MESSAGE =
|
|
13
13
|
"Waits on time in a story or reachable test-support: a sleep, a real timer, a wall-clock read such as Date.now(), polling with eventually or waitFor, fake timers or a clock adjustment in the spec. Settle on the engine's own signal through a kit verb, such as a Deferred the engine completes, story.runUntil or screenDriver's settle(). A deadline bounds a failure but does not prove completion; reaching it must fail the story. When time passing is the behaviour, name it in a kit verb that advances TestClock.";
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import type { Chain, Layer } from "#adapters/biome/configs.ts";
|
|
2
|
-
import { scoped } from "
|
|
3
|
-
import { entriesOf, isFalse, itemsOf, type Json, member, textOf } from "
|
|
2
|
+
import { scoped } from "#rules/suppressions/biome/declarations.ts";
|
|
3
|
+
import { entriesOf, isFalse, itemsOf, type Json, member, textOf } from "#rules/suppressions/biome/json.ts";
|
|
4
4
|
|
|
5
5
|
export interface Weakening {
|
|
6
6
|
readonly includes: readonly string[];
|
|
@@ -3,8 +3,8 @@ import ts from "typescript";
|
|
|
3
3
|
import { defineRule, type Finding, type RuleInputs, type SourceFile } from "#rule.ts";
|
|
4
4
|
import { effectProgram } from "#rules/effect/program.ts";
|
|
5
5
|
import { parse } from "#rules/parse.ts";
|
|
6
|
-
import { hiddenCast, SQL_ROW_CAST } from "
|
|
7
|
-
import { readonlyWrite, writeCandidate } from "
|
|
6
|
+
import { hiddenCast, SQL_ROW_CAST } from "#rules/suppressions/hiddenCast.ts";
|
|
7
|
+
import { readonlyWrite, writeCandidate } from "#rules/suppressions/readonlyWrite.ts";
|
|
8
8
|
|
|
9
9
|
const BRIDGES: ReadonlyMap<ts.SyntaxKind, string> = new Map([
|
|
10
10
|
[ts.SyntaxKind.UnknownKeyword, "unknown"],
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { defineRule, type Finding, type RuleInputs } from "#rule.ts";
|
|
2
2
|
import { type SourceComment, scanComments } from "#rules/comments/scan.ts";
|
|
3
|
-
import { suppressionIn } from "
|
|
4
|
-
import { STYLESHEET, stylesheetComments } from "
|
|
3
|
+
import { suppressionIn } from "#rules/suppressions/in.ts";
|
|
4
|
+
import { STYLESHEET, stylesheetComments } from "#rules/suppressions/stylesheetComments.ts";
|
|
5
5
|
|
|
6
6
|
const TYPE_TEST = /(?:(?:^|\/)typecheck\.test|\.typecheck\.(?:test|spec))\.[cm]?[jt]sx?$/u;
|
|
7
7
|
|
|
@@ -3,10 +3,10 @@ import { chmodSync, existsSync, mkdirSync, readFileSync, statSync, writeFileSync
|
|
|
3
3
|
import { dirname, join } from "node:path";
|
|
4
4
|
import sortPackageJson from "sort-package-json";
|
|
5
5
|
import { shellWords } from "#hooks/command.ts";
|
|
6
|
-
import { qualityArgs, type Run } from "
|
|
7
|
-
import { commitAll, git, isolatedEnvironment } from "
|
|
8
|
-
import { formatTree } from "
|
|
9
|
-
import { DEFAULT_FILES, linkPackage, type SeedFile, seedTree } from "
|
|
6
|
+
import { qualityArgs, type Run } from "#testing/adapters/cli.ts";
|
|
7
|
+
import { commitAll, git, isolatedEnvironment } from "#testing/adapters/git.ts";
|
|
8
|
+
import { formatTree } from "#testing/adapters/qualityTree.ts";
|
|
9
|
+
import { DEFAULT_FILES, linkPackage, type SeedFile, seedTree } from "#testing/adapters/tree.ts";
|
|
10
10
|
|
|
11
11
|
export interface HookRepository {
|
|
12
12
|
readonly folder: string;
|
|
@@ -103,11 +103,7 @@ export function withScripts(root: string, scripts: Readonly<Record<string, strin
|
|
|
103
103
|
|
|
104
104
|
export function withQualityAt(repository: HookRepository, path: string): string {
|
|
105
105
|
writes(repository.root, path, 'import "@shivaedev/quality/cli.ts";\n');
|
|
106
|
-
writes(
|
|
107
|
-
repository.root,
|
|
108
|
-
"package.json",
|
|
109
|
-
manifest({ bin: { quality: `./${path}` }, devDependencies: { "@shivaedev/quality": "file:./node_modules/@shivaedev/quality" } }),
|
|
110
|
-
);
|
|
106
|
+
writes(repository.root, "package.json", manifest({ bin: { quality: `./${path}` }, devDependencies: { "@shivaedev/quality": "0.0.0" } }));
|
|
111
107
|
formatTree(repository.root);
|
|
112
108
|
return join(repository.root, path);
|
|
113
109
|
}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { spawnSync } from "node:child_process";
|
|
2
2
|
import { createRequire } from "node:module";
|
|
3
3
|
import process from "node:process";
|
|
4
|
-
import { linkPackage, type SeedFile, seedTree } from "
|
|
4
|
+
import { linkPackage, type SeedFile, seedTree } from "#testing/adapters/tree.ts";
|
|
5
5
|
|
|
6
6
|
const BIN = createRequire(import.meta.url).resolve("@biomejs/biome/bin/biome");
|
|
7
7
|
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { mkdirSync, writeFileSync } from "node:fs";
|
|
2
2
|
import { dirname, join } from "node:path";
|
|
3
|
-
import { packageExports } from "
|
|
3
|
+
import { packageExports } from "#testing/adapters/packageExports.ts";
|
|
4
4
|
|
|
5
5
|
export function writePackageExports(root: string, exports: unknown, path: string): void {
|
|
6
6
|
const target = join(root, path);
|