Rename and update parallel testcase

This commit is contained in:
Joël Stemmer 2018-03-17 19:35:50 +00:00
parent 766f2ff9bb
commit 6f96942bb2
3 changed files with 18 additions and 9 deletions

View File

@ -766,12 +766,12 @@ var testCases = []TestCase{
},
},
{
name: "20-trio.txt",
name: "20-parallel.txt",
reportName: "20-report.xml",
report: &parser.Report{
Packages: []parser.Package{
{
Name: "",
Name: "pkg/parallel",
Time: 3010,
Tests: []*parser.Test{
{
@ -781,6 +781,7 @@ var testCases = []TestCase{
Output: []string{
"Message from first",
"Supplemental from first",
"parallel_test.go:14: FirstTest error",
},
},
{
@ -789,6 +790,7 @@ var testCases = []TestCase{
Result: parser.FAIL,
Output: []string{
"Message from second",
"parallel_test.go:23: SecondTest error",
},
},
{
@ -797,6 +799,7 @@ var testCases = []TestCase{
Result: parser.FAIL,
Output: []string{
"Message from third",
"parallel_test.go:32: ThirdTest error",
},
},
},

View File

@ -9,5 +9,11 @@ Supplemental from first
=== RUN ThirdTest
Message from third
--- FAIL: ThirdTest (0.01s)
parallel_test.go:32: ThirdTest error
--- FAIL: FirstTest (2.00s)
parallel_test.go:14: FirstTest error
--- FAIL: SecondTest (1.00s)
parallel_test.go:23: SecondTest error
FAIL
exit status 1
FAIL pkg/parallel 3.010s

View File

@ -1,17 +1,17 @@
<?xml version="1.0" encoding="UTF-8"?>
<testsuites>
<testsuite tests="3" failures="3" time="3.010" name="">
<testsuite tests="3" failures="3" time="3.010" name="pkg/parallel">
<properties>
<property name="go.version" value="1.0"></property>
</properties>
<testcase classname="" name="FirstTest" time="2.000">
<failure message="Failed" type="">Message from first&#xA;Supplemental from first</failure>
<testcase classname="parallel" name="FirstTest" time="2.000">
<failure message="Failed" type="">Message from first&#xA;Supplemental from first&#xA;parallel_test.go:14: FirstTest error</failure>
</testcase>
<testcase classname="" name="SecondTest" time="1.000">
<failure message="Failed" type="">Message from second</failure>
<testcase classname="parallel" name="SecondTest" time="1.000">
<failure message="Failed" type="">Message from second&#xA;parallel_test.go:23: SecondTest error</failure>
</testcase>
<testcase classname="" name="ThirdTest" time="0.010">
<failure message="Failed" type="">Message from third</failure>
<testcase classname="parallel" name="ThirdTest" time="0.010">
<failure message="Failed" type="">Message from third&#xA;parallel_test.go:32: ThirdTest error</failure>
</testcase>
</testsuite>
</testsuites>