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

Update makefile to use examples harness #30

Merged
Merged
Changes from all commits
Commits
File filter...
Filter file types
Jump to…
Jump to file
Failed to load files.

Always

Just for now

@@ -1,7 +1,7 @@
# Common User Targets:
#
# make tests
# - Sxecute the tests
# - Execute the tests
#
# make shell
# - Set up the environment and drop to a shell (re-uses existing shells if they
@@ -40,12 +40,34 @@ NOTICE = @notice() { printf "\n${COL_NOTICE}+++ %s${COL_RESET}\n" "$$@"; } && no
GOOD = @notice() { printf "\n${COL_GOOD}+++ %s${COL_RESET}\n" "$$@"; } && notice


tests: test_testable
${NOTICE} "Running tests"
tests: test_level_system
${GOOD} "All tests passed"

# 'test_level_*' targets run all the tests up to that level
test_level_unittests: unittests
test_level_integration: test_level_unittests integrationtests
test_level_system: test_level_integration systemtests

# Unit tests test individual parse of a small unit.
unittests: test_testable
${NOTICE} "Running unit tests"
${GOOD} "Unit tests passed (we don't have any yet)"

# Integration tests check the integration of those units.
integrationtests: test_testable
${NOTICE} "Running integration tests"
@# Note: We cd into the tests directory, so that we are testing the installed version, not
@# the version in the repository.
${ACTIVATE} && cd tests && python -munittest -v ${TEST_MODULES}
${GOOD} "Tests passed"
${GOOD} "Integration tests passed"

# System tests check that the way that a user might use it works.
systemtests: test_testable
${NOTICE} "Running system tests"
@# We only run 1000 runs; just enough that we get to see that it's running the tests.
${ACTIVATE} && examples/run_all_examples.py --runs 1000
${GOOD} "System tests passed"


venv: venv/successful-${PYTHON_TOOL}

ProTip! Use n and p to navigate between commits in a pull request.
You can’t perform that action at this time.