Skip to content

Commit

Permalink
test: don't include output when nothing has been changed by fixers
Browse files Browse the repository at this point in the history
  • Loading branch information
G-Rath committed Sep 25, 2024
1 parent 710930e commit f3e8eda
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion tests/src/rule-tester.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ import semver from 'semver';
export const usingFlatConfig = semver.major(eslintVersion) >= 9;

export function withoutAutofixOutput(test) {
return { ...test, output: test.code };
return { ...test, ...usingFlatConfig || { output: test.code } };
}

export class FlatCompatRuleTester {
Expand Down

0 comments on commit f3e8eda

Please sign in to comment.