fix JUnit report format
Fixes #273 & #304
I added two new types to handle the JUnit specific marshaling. This probably can be implemented a bit better rather than inline structs + new types just for making encoding/xml happy.
tests pass. Had to make a tweak to tests/structure_test_tests.sh get the script to run correctly. Could use a pair of eyes to make sure its kosher 👀
$ make test
GOOS=linux GOARCH=amd64 CGO_ENABLED=0 go build -ldflags " -X github.com/GoogleContainerTools/container-structure-test/pkg/version.version=v1.11.0 -X github.com/GoogleContainerTools/container-structure-test/pkg/version.buildDate=2022-09-10T23:12:32Z " -o out/container-structure-test-linux-amd64 github.com/GoogleContainerTools/container-structure-test/cmd/container-structure-test
cp ./out/container-structure-test-linux-amd64 out/container-structure-test
./tests/structure_test_tests.sh
##
# Build the newest 'container structure test' binary
##
make[1]: Entering directory '/home/tom/oss/container-structure-test'
make[1]: 'out/container-structure-test' is up to date.
make[1]: Leaving directory '/home/tom/oss/container-structure-test'
make[1]: Entering directory '/home/tom/oss/container-structure-test'
shasum -a 256 out/container-structure-test-linux-amd64 &> out/container-structure-test-linux-amd64.sha256
GOOS=darwin GOARCH=amd64 CGO_ENABLED=0 go build -ldflags " -X github.com/GoogleContainerTools/container-structure-test/pkg/version.version=v1.11.0 -X github.com/GoogleContainerTools/container-structure-test/pkg/version.buildDate=2022-09-10T23:12:33Z " -o out/container-structure-test-darwin-amd64 github.com/GoogleContainerTools/container-structure-test/cmd/container-structure-test
1af7e99e80ab87be17e42c2215775213b00bf26b94d912e841e13074c2aa1e28 out/container-structure-test-linux-amd64
shasum -a 256 out/container-structure-test-darwin-amd64 &> out/container-structure-test-darwin-amd64.sha256
GOOS=windows GOARCH=amd64 CGO_ENABLED=0 go build -ldflags " -X github.com/GoogleContainerTools/container-structure-test/pkg/version.version=v1.11.0 -X github.com/GoogleContainerTools/container-structure-test/pkg/version.buildDate=2022-09-10T23:12:33Z " -o out/container-structure-test-windows-amd64 github.com/GoogleContainerTools/container-structure-test/cmd/container-structure-test
cb459a834dd408c3c49871996de887ef4869e1b3a39969ddbc5bbb40ea4eb5e3 out/container-structure-test-darwin-amd64
cp out/container-structure-test-windows-amd64 out/container-structure-test-windows-amd64.exe
shasum -a 256 out/container-structure-test-windows-amd64.exe &> out/container-structure-test-windows-amd64.exe.sha256
rm out/container-structure-test-windows-amd64
make[1]: Leaving directory '/home/tom/oss/container-structure-test'
make[1]: Entering directory '/home/tom/oss/container-structure-test'
docker build -t gcr.io/gcp-runtimes/container-structure-test:latest .
b52f3be912ee64f74d5ea8b976a1810c44d361b050ebdbcc30192549343fbd31 out/container-structure-test-windows-amd64.exe
Sending build context to Docker daemon 75.7MB
Step 1/3 : FROM ubuntu:20.04
---> a0ce5a295b63
Step 2/3 : ADD out/container-structure-test /container-structure-test
---> 0baf39323714
Step 3/3 : ENTRYPOINT ["/container-structure-test"]
---> Running in 45c8c2fdfbe1
Removing intermediate container 45c8c2fdfbe1
---> d6e10d9b923c
Successfully built d6e10d9b923c
Successfully tagged gcr.io/gcp-runtimes/container-structure-test:latest
make[1]: Leaving directory '/home/tom/oss/container-structure-test'
##
# Positive Test Case
##
PASS: Success test case passed
##
# Metadata Test Case
##
PASS: Metadata success test case for docker driver
PASS: Metadata success test case for tar driver
PASS: Metadata success test case for host driver
##
# Failure Test Case
##
FATA[0000] FAIL
PASS: Failure test failed
###
# OCI layout test case
###
PASS: oci failing test case
PASS: oci success test case
Thanks for your pull request! It looks like this may be your first contribution to a Google open source project. Before we can look at your pull request, you'll need to sign a Contributor License Agreement (CLA).
View this failed invocation of the CLA check for more information.
For the most up to date status, view the checks section at the bottom of the pull request.
I'm not actually sure what this integration test is waiting for. If you want to trigger this with some sort of rebase or other minor change, maybe we can merge it in.
1 workflow awaiting approval First-time contributors need a maintainer to approve running workflows. Learn more.
Looks like it's waiting on a manual approval. @loosebazooka would you mind kicking it off? EDIT: There are some test failures I'm working through.
@nkubala or @dlorenc , would either of you folks be able to approve the workflow & run the tests (should be passing now)?
Yeah I dunno what's going on. But I approved it now