Created
May 21, 2023 10:47
-
-
Save tasaquino/b8267d27fc2e71c9ca2890bef524d138 to your computer and use it in GitHub Desktop.
Script to run flutter tests with code coverage and generate html report from lcov file
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# allow the script to be executed chmod +x ./flutter_coverage_script.sh | |
echo '========== Executing tests...' | |
cd flutter test --coverage # `coverage/lcov.info` file | |
echo '========== Converting cov.info into html...' | |
genhtml coverage/lcov.info -o coverage/html # converts coverage report in html | |
echo '========== Opening html coverage report...' | |
open coverage/html/index.html | |
echo '========== Report is complete :)' |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment