I would like to use Test Reports dashboard in my Flutter build workflow, but I’m unable to correctly export a junit test report.
I have a following step:
- firstname.lastname@example.org: inputs: - content: | #!/usr/bin/env bash # fail if any commands fails set -e # debug log set -x brew tap dart-lang/dart brew install dart # dart for junitreport cd $BITRISE_SOURCE_DIR/$BITRISE_FLUTTER_PROJECT_LOCATION mkdir tests flutter pub pub global activate junitreport export PATH="$PATH":"$HOME/.pub-cache/bin" flutter test --machine | tojunit > $BITRISE_SOURCE_DIR/$BITRISE_FLUTTER_PROJECT_LOCATION/tests/TEST-report.xml - email@example.com: inputs: - deploy_path: "$BITRISE_FLUTTER_PROJECT_LOCATION/tests"
This runs flutter tests and exports the results to TEST-report.xml (junit file).
In logs I can see that deploy executes with success:
Deploying the content of the Deploy directory separately List of files to deploy - /Users/vagrant/git/mobile/app/tests/TEST-report.xml Deploying files Uploading file: /Users/vagrant/git/app/employee/tests/TEST-report.xml creating artifact file size: 3608B uploading artifact % Total % Received % Xferd Average Speed Time Time Time Current Dload Upload Total Spent Left Speed 0 0 0 0 0 0 0 0 --:--:-- --:--:-- --:--:-- 0 100 3608 0 0 100 3608 0 13550 --:--:-- --:--:-- --:--:-- 13563 finishing artifact is_enable_public_page is set, but public download isn't allowed for this type of file Success You can find the Artifact on Bitrise, on the Build's page: https://app.bitrise.io/build/8aca429a3e5e3c2f Upload test results - uploading (0) test results Success
However, TEST-results.xml file is not recognized as test result. Is there any way to manually set this file as a source for tests results?
Example build slug: