@@ -76,13 +76,20 @@ suite('E2E Server Linter', () => {
7676 } ) ;
7777 }
7878
79- // TODO: fix flaky test, somehow broken since 25-12-16
79+ // TODO: fix flaky test, broken since 25-12-16
80+ // the `.oxlintrc.json` is not picked up correctly and `no-empty-file` is still enabled
8081 test . skip ( 'detects diagnostics on run' , async ( ) => // testSingleFolderMode
8182 {
83+ // const config = new VSCodeConfig();
84+ // config.updateTrace('verbose');
85+ // await commands.executeCommand('oxc.showOutputChannel');
86+
8287 await loadFixture ( 'lint_on_run' ) ;
8388 await sleep ( 500 ) ;
8489 const diagnostics = await getDiagnosticsWithoutClose ( `onType.ts` ) ;
85- strictEqual ( diagnostics . length , 0 ) ;
90+ // process.stdout.write(JSON.stringify(diagnostics, null, 2));
91+
92+ strictEqual ( diagnostics . length , 0 , 'no diagnostics expected initially' ) ;
8693
8794 await writeToFixtureFile ( 'onType.ts' , 'debugger;' ) ;
8895 await waitForDiagnosticChange ( ) ;
@@ -92,15 +99,14 @@ suite('E2E Server Linter', () => {
9299 await workspace . saveAll ( ) ;
93100 await sleep ( 500 ) ;
94101
95- const sameDiagnostics = await getDiagnosticsWithoutClose ( `onType.ts` ) ;
102+ const sameDiagnostics = await getDiagnostics ( `onType.ts` ) ;
96103 strictEqual ( updatedDiagnostics . length , sameDiagnostics . length ) ;
97104 } ) ;
98105
99- // TODO: fix flaky test, somehow broken since 25-12-16
100- test . skip ( 'empty oxlint configuration behaves like default configuration' , async ( ) => {
106+ test ( 'empty oxlint configuration behaves like default configuration' , async ( ) => {
101107 await loadFixture ( 'debugger_empty_config' ) ;
102108 await sleep ( 500 ) ;
103- const diagnostics = await getDiagnosticsWithoutClose ( 'debugger.js' ) ;
109+ const diagnostics = await getDiagnostics ( 'debugger.js' , undefined , 500 ) ;
104110
105111 strictEqual ( diagnostics . length , 1 ) ;
106112 assert ( typeof diagnostics [ 0 ] . code == 'object' ) ;
0 commit comments