Uh oh!
There was an error while loading.Please reload this page.
- Notifications
You must be signed in to change notification settings - Fork2.8k
feat(rule-tester): switched to flat config#9603
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to ourterms of service andprivacy statement. We’ll occasionally send you account related emails.
Already on GitHub?Sign in to your account
feat(rule-tester): switched to flat config#9603
Uh oh!
There was an error while loading.Please reload this page.
Conversation
Thanks for the PR,@JoshuaKGoldberg! typescript-eslint is a 100% community driven project, and we are incredibly grateful that you are contributing to that community. The core maintainers work on this in their personal time, so please understand that it may not be possible for them to review your work immediately. Thanks again! 🙏Please, if you or your company is finding typescript-eslint valuable, help us sustain the project by sponsoring it transparently onhttps://opencollective.com/typescript-eslint. |
netlifybot commentedJul 22, 2024 • edited
Loading Uh oh!
There was an error while loading.Please reload this page.
edited
Uh oh!
There was an error while loading.Please reload this page.
✅ Deploy Preview fortypescript-eslint ready!
To edit notification comments on pull requests, go to yourNetlify site configuration. |
nx-cloudbot commentedJul 22, 2024 • edited
Loading Uh oh!
There was an error while loading.Please reload this page.
edited
Uh oh!
There was an error while loading.Please reload this page.
bradzacher commentedJul 22, 2024
Thought: I wonder if we should have hoisted up our stuff / the common stuff to avoid churn. Cos this will mess with all the ecosystem as well. I know that was their intent but it is going to block plugins hard. |
…ns/wrappers; hacked around [] getConfig
JoshuaKGoldberg commentedJul 22, 2024 • edited
Loading Uh oh!
There was an error while loading.Please reload this page.
edited
Uh oh!
There was an error while loading.Please reload this page.
Yeah I don't think we're in a good place to do anything here. +1 that this will be work for plugins, but:
|
Uh oh!
There was an error while loading.Please reload this page.
Uh oh!
There was an error while loading.Please reload this page.
Co-authored-by: Brad Zacher <brad.zacher@gmail.com>
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@## v8 #9603 +/- ##==========================================+ Coverage 88.00% 88.01% +0.01%========================================== Files 401 401 Lines 13647 13637 -10 Branches 3965 3960 -5 ==========================================- Hits 12010 12003 -7 Misses 1325 1325+ Partials 312 309 -3
Flags with carried forward coverage won't be shown.Click here to find out more.
|

Uh oh!
There was an error while loading.Please reload this page.
BREAKING CHANGE:
Switches
RuleTesterfrom legacy configs to flat configs.PR Checklist
Overview
Switches the internals of our forked
RuleTesterto work withnew Linter({ configType: 'flat' });instead ofconfigType: 'eslintrc'. This is a pretty substantial breaking change internally:this.#linteris no longer able todefineRule()ad hoc; instead, theconfig: TesterConfigWithDefaultshas to havepluginsincluding the rule.@/plugin can't be redefined, a@rule-tester/prefix is added in front of rule names.parser,parserOptions, and other language-specific settings are moved tolanguageOptions.parserhas to be the actual parser, not a string descriptor.parser: '@typescript-eslint/parser',parserOptions: { sourceType: 'module' }, and other seemingly unnecessary options from our test files@typescript-eslint/utilsRuleTesterre-export as deprecatedI think we'll want to follow this up with added info in the v8 beta blog post. See our
packages/eslint-plugin(-internal)/**/*.test.tsfile changes. There's a fair amount users will have to do:lib,parser,parserOptions,sourceType, and any other parser options insidelanguageOptionsparserfrom astringto the actual parserecmaVersionandsourceTypeare now'latest'and'module', respectively💖