parser/gotest: support parsing test summaries when there were no tests

This commit is contained in:
Joël Stemmer
2022-03-13 00:22:02 +00:00
parent 458fe89a9a
commit a70d508a2e
5 changed files with 56 additions and 6 deletions

5
testdata/34-notest.txt vendored Normal file
View File

@ -0,0 +1,5 @@
? package/name [no test files]
testing: warning: no tests to run
PASS
ok package/name 0.001s [no tests to run]
ok package/name (cached) [no tests to run]

18
testdata/34-report.xml vendored Normal file
View File

@ -0,0 +1,18 @@
<?xml version="1.0" encoding="UTF-8"?>
<testsuites>
<testsuite tests="0" failures="0" errors="0" time="0.000" name="package/name" hostname="hostname" timestamp="2022-01-01T00:00:00Z">
<properties>
<property name="go.version" value="1.0"></property>
</properties>
</testsuite>
<testsuite tests="0" failures="0" errors="0" time="0.001" name="package/name" hostname="hostname" timestamp="2022-01-01T00:00:00Z">
<properties>
<property name="go.version" value="1.0"></property>
</properties>
</testsuite>
<testsuite tests="0" failures="0" errors="0" time="0.000" name="package/name" hostname="hostname" timestamp="2022-01-01T00:00:00Z">
<properties>
<property name="go.version" value="1.0"></property>
</properties>
</testsuite>
</testsuites>