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_bitcoin should be build only when executing make check #261

Closed
ultimaweapon opened this issue Sep 24, 2018 · 3 comments · Fixed by #360
Closed

test_bitcoin should be build only when executing make check #261

ultimaweapon opened this issue Sep 24, 2018 · 3 comments · Fixed by #360

Comments

@ultimaweapon
Copy link
Contributor

Right now it build when we run make. This will reduce a lot of build time when we don't need to build unit tests. What we need to do is changing bin_PROGRAMS += test/test_bitcoin in src/Makefile.test.include to check_PROGRAMS instead (consult document for more details). This should also prevent test_bitcoin to install when we execute make install too.

We may also rename test_bitcoin to test_zcoin too :)

@ultimaweapon ultimaweapon self-assigned this Oct 10, 2018
@ultimaweapon
Copy link
Contributor Author

Even changing bin_PROGRAMS to check_PROGRAMS still build unit tests (normally it will not). Look like there is some weird rules in build script that need to look on.

@ultimaweapon ultimaweapon removed their assignment Oct 10, 2018
@riordant
Copy link
Contributor

riordant commented Mar 5, 2019

I'm not sure if I agree with this. I would prefer the behaviour that after altering files in src/test, they can continue to be built with make rather than make check. It's straightforward to disable building tests altogether with the ENABLE_TESTS flag.

@ultimaweapon
Copy link
Contributor Author

The main issue is it build test by default when run make which is not expected behavior. Most GNU Autotools project will build test only when requested by user (which is make check). Another issue is it also install test_bitcoin binary too, which should not. We may leave the current behavior and change the default value for ENABLE_TESTS to not build test by default.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants