diff --git a/messages/results-writer.md b/messages/results-writer.md index b29c1060c..03076e48e 100644 --- a/messages/results-writer.md +++ b/messages/results-writer.md @@ -1,3 +1,3 @@ # error.unrecognized-file-format -The output file %s has an unsupported extension. Valid extensions include: .csv; .html/.htm; .json; .junit/.junit.xml; .sarif/.sarif.json; .xml. +The output file %s has an unsupported extension. Valid extensions include: .csv; .html/.htm; .json; .sarif/.sarif.json; .xml. diff --git a/messages/run-command.md b/messages/run-command.md index ee74f6edf..d001a3cc7 100644 --- a/messages/run-command.md +++ b/messages/run-command.md @@ -133,7 +133,6 @@ If you don't specify this flag, the command outputs the results in the terminal. - .csv - .html or .htm - .json -- .junit or .junit.xml - .sarif or .sarif.json - .xml diff --git a/src/lib/writers/ResultsWriter.ts b/src/lib/writers/ResultsWriter.ts index 4fcae8a7c..0f6acf073 100644 --- a/src/lib/writers/ResultsWriter.ts +++ b/src/lib/writers/ResultsWriter.ts @@ -39,9 +39,6 @@ export class ResultsFileWriter implements ResultsWriter { // Check for `.json` AFTER checking for `.sarif.json`! } else if (ext === '.json') { this.format = OutputFormat.JSON; - } else if (ext === '.junit' || file.toLowerCase().endsWith('.junit.xml')) { - throw new Error('TODO: Support JUNIT-type output'); - // Check for `.xml` AFTER checking for `.junit.xml`! } else if (ext === '.xml') { this.format = OutputFormat.XML; } else { diff --git a/test/lib/writers/ResultsWriter.test.ts b/test/lib/writers/ResultsWriter.test.ts index 9fc6a6c02..b8f2ca632 100644 --- a/test/lib/writers/ResultsWriter.test.ts +++ b/test/lib/writers/ResultsWriter.test.ts @@ -23,8 +23,6 @@ describe('ResultsWriter implementations', () => { {ext: '.html', expectedOutput: `Results formatted as ${OutputFormat.HTML}`}, {ext: '.htm', expectedOutput: `Results formatted as ${OutputFormat.HTML}`}, {ext: '.json', expectedOutput: `Results formatted as ${OutputFormat.JSON}`}, - //{ext: '.junit', expectedOutput: `Results formatted as ${OutputFormat.JUNIT}`}, - //{ext: '.junit.xml', expectedOutput: `Results formatted as ${OutputFormat.JUNIT}`}, //{ext: '.sarif', expectedOutput: `Results formatted as ${OutputFormat.SARIF}`}, //{ext: '.sarif.json', expectedOutput: `Results formatted as ${OutputFormat.SARIF}`}, {ext: '.xml', expectedOutput: `Results formatted as ${OutputFormat.XML}`} @@ -48,8 +46,6 @@ describe('ResultsWriter implementations', () => { * in the case array for the valid format tests. */ it.each([ - {ext: '.junit'}, - {ext: '.junit.xml'}, {ext: '.sarif'}, {ext: '.sarif.json'} ])('Throws TODO error for not-yet-supported format: *$ext', ({ext}) => {