Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

test: run unittests on test_dmd target for ci.sh #13626

Closed
wants to merge 1 commit into from

Conversation

ljmf00
Copy link
Member

@ljmf00 ljmf00 commented Feb 9, 2022

Signed-off-by: Luís Ferreira contact@lsferreira.net

@dlang-bot
Copy link
Contributor

dlang-bot commented Feb 9, 2022

Thanks for your pull request, @ljmf00!

Bugzilla references

Your PR doesn't reference any Bugzilla issue.

If your PR contains non-trivial changes, please reference a Bugzilla issue or create a manual changelog.

Testing this PR locally

If you don't have a local development environment setup, you can use Digger to test this PR:

dub run digger -- build "master + dmd#13626"

test/Makefile Outdated Show resolved Hide resolved
@MoonlightSentinel
Copy link
Contributor

MoonlightSentinel commented Feb 9, 2022

Note that the unit tests are already run e.g. on Azure, see

targets=("all")
args=('ARGS=-O -inline -g') # no -release for faster builds
if [ "$HOST_DMD_VERSION" = "2.079.0" ] ; then
# skip runnable_cxx and unit_tests with older bootstrap compilers
targets=("runnable" "compilable" "fail_compilation" "dshell")
args=() # use default set of args
fi
CC="$CC" ./run --environment --jobs=$N "${targets[@]}" "${args[@]}"
.

They are also explicitly disabled for bootstrap tests because some tests require a more recent host compiler.

EDIT: Given the state of the auto-tester it's probably better to leave the makefile unchanged and rather use run.d directly from ci.sh

@ljmf00
Copy link
Member Author

ljmf00 commented Feb 9, 2022

Note that the unit tests are already run e.g. on Azure, see

Does that target generate coverage? auto-tester-test target is used on Cirrus CI tests too.

@ljmf00 ljmf00 changed the title test: run unittests on auto-tester-test target test: run unittests on test_dmd target for ci.sh Feb 9, 2022
Co-authored-by: Florian <moonlightsentinel@disroot.org>
Signed-off-by: Luís Ferreira <contact@lsferreira.net>
@ljmf00
Copy link
Member Author

ljmf00 commented Feb 9, 2022

This seems to not merge the coverage reports. @RazvanN7 can you explain to me how the test runner merges coverage? I don't see any presence of --DRT-covopt="merge:1" and I'm not aware of the testing infrastructure good enough. Also, ./test/run.d -u and ./test/run.d unit_tests runs unit_test_runner on a different folders producing coverage on different places. The coverage is not being reported particularly, because ./test/run.d unit_tests runs inside ./test/ folder as its current working directory and before uploading codecov.sh does the following:

rm -rf test/runnable/extra-files test/*.lst

@MoonlightSentinel
Copy link
Contributor

Does that target generate coverage? auto-tester-test target is used on Cirrus CI tests too.

Yes, allthough there's currently an issue that will be resolved in #13535 - just need to do some more debugging

@ljmf00
Copy link
Member Author

ljmf00 commented Feb 17, 2022

Superseded by #13628 .

@ljmf00 ljmf00 closed this Feb 17, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
3 participants