From 34f1c566ff37c6839418102e3cc501d38efe2a6d Mon Sep 17 00:00:00 2001 From: Shamus Taylor Date: Mon, 21 Apr 2025 15:26:42 -0500 Subject: [PATCH] register parser and update readme --- README.md | 9 +++++++++ src/main.ts | 3 +++ 2 files changed, 12 insertions(+) diff --git a/README.md b/README.md index e5abd85..676d21e 100644 --- a/README.md +++ b/README.md @@ -16,6 +16,7 @@ This [Github Action](https://github.com/features/actions) displays test results - .NET / [dotnet test](https://docs.microsoft.com/en-us/dotnet/core/tools/dotnet-test#examples) ( [xUnit](https://xunit.net/) / [NUnit](https://nunit.org/) / [MSTest](https://github.com/Microsoft/testfx-docs) ) - Dart / [test](https://pub.dev/packages/test) - Flutter / [test](https://pub.dev/packages/test) +- Go / [go test](https://pkg.go.dev/testing) - Java / [JUnit](https://junit.org/) - JavaScript / [JEST](https://jestjs.io/) / [Mocha](https://mochajs.org/) - Swift / xUnit @@ -140,6 +141,7 @@ jobs: # dotnet-nunit # dotnet-trx # flutter-json + # golang-json # java-junit # jest-junit # mocha-json @@ -278,6 +280,13 @@ For more information see: +
+ golang-json + +You must use the `-json` flag and output the results to a file (ex: `go test -json > testresults.json`) + +
+
java-junit (Experimental) diff --git a/src/main.ts b/src/main.ts index 109d75b..b018390 100644 --- a/src/main.ts +++ b/src/main.ts @@ -13,6 +13,7 @@ import {getReport} from './report/get-report' import {DartJsonParser} from './parsers/dart-json/dart-json-parser' import {DotnetNunitParser} from './parsers/dotnet-nunit/dotnet-nunit-parser' import {DotnetTrxParser} from './parsers/dotnet-trx/dotnet-trx-parser' +import {GolangJsonParser} from './parsers/golang-json/golang-json-parser' import {JavaJunitParser} from './parsers/java-junit/java-junit-parser' import {JestJunitParser} from './parsers/jest-junit/jest-junit-parser' import {MochaJsonParser} from './parsers/mocha-json/mocha-json-parser' @@ -248,6 +249,8 @@ class TestReporter { return new DotnetNunitParser(options) case 'dotnet-trx': return new DotnetTrxParser(options) + case 'golang-json': + return new GolangJsonParser(options) case 'flutter-json': return new DartJsonParser(options, 'flutter') case 'java-junit':