File tree Expand file tree Collapse file tree
test-helpers/src/startFixture Expand file tree Collapse file tree Original file line number Diff line number Diff line change 1+ {
2+ "$schema" : " ./node_modules/oxlint/configuration_schema.json" ,
3+ "ignorePatterns" : [" packages/webpack-plugin/extracted.js" ]
4+ }
Original file line number Diff line number Diff line change @@ -46,15 +46,15 @@ export class ConditionalRuleset {
4646 }
4747
4848 getConditionalRulesetByPath ( conditionPath : Array < Query > ) : ConditionalRuleset {
49- let currRuleset : ConditionalRuleset = this ;
49+ let currRuleset : ConditionalRuleset | undefined ;
5050
5151 for ( const query of conditionPath ) {
52- const condition = currRuleset . findOrCreateCondition ( query ) ;
52+ const condition = this . findOrCreateCondition ( query ) ;
5353
5454 currRuleset = condition . children ;
5555 }
5656
57- return currRuleset ;
57+ return currRuleset || this ;
5858 }
5959
6060 addRule (
Original file line number Diff line number Diff line change @@ -34,6 +34,8 @@ export const startParcelFixture = async (
3434 logLevel : 'verbose' ,
3535 } ) ;
3636
37+ // Not sure how to remove the `async` here
38+ // oxlint-disable-next-line no-async-promise-executor
3739 return new Promise ( async ( resolve , reject ) => {
3840 const subscription = await bundler . watch ( ( err , buildEvent ) => {
3941 if ( err ) {
Original file line number Diff line number Diff line change @@ -7,6 +7,8 @@ type TestFixtures = {
77let testCounter = 0 ;
88
99const test = base . extend < TestFixtures > ( {
10+ // Playwright has to have a destructure as the first arg for some reason
11+ // oxlint-disable-next-line no-empty-pattern
1012 port : async ( { } , use , workerInfo ) => {
1113 const portRange = 100 * workerInfo . workerIndex ;
1214 await use ( 9000 + portRange + testCounter ++ ) ;
Original file line number Diff line number Diff line change @@ -7,6 +7,7 @@ const noop = (..._args: Array<any>) => {};
77
88type AssertIsString < S > = S extends string ? true : never ;
99
10+ // oxlint-disable-next-line no-unused-expressions
1011( ) => {
1112 const textRecipes = recipe ( {
1213 variants : {
Original file line number Diff line number Diff line change @@ -19,6 +19,7 @@ import {
1919
2020const noop = ( ..._args : Array < any > ) => { } ;
2121
22+ // oxlint-disable-next-line no-unused-expressions
2223( ) => {
2324 const sprinkles = createSprinkles (
2425 propertiesWithShorthands ,
@@ -142,9 +143,11 @@ const noop = (..._args: Array<any>) => {};
142143 testGenericNormalizeValue ( '' ) ;
143144
144145 // @ts -expect-error - Strings shouldn't map to objects
146+ // oxlint-disable-next-line no-unused-expressions
145147 mapValue ( alignProp , ( ) => 'baz' ) . mobile ;
146148
147149 // @ts -expect-error - Numbers shouldn't map to objects
150+ // oxlint-disable-next-line no-unused-expressions
148151 mapValue ( 3 , ( ) => 4 ) . mobile ;
149152
150153 const mapValueWithoutDefaultCondition = createMapValueFn (
You can’t perform that action at this time.
0 commit comments