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

Improve documentation for running unit tests #1868

Open
doug-walker opened this issue Sep 22, 2023 · 2 comments · May be fixed by #1947
Open

Improve documentation for running unit tests #1868

doug-walker opened this issue Sep 22, 2023 · 2 comments · May be fixed by #1947
Assignees
Labels
Documentation Documentation related development and/or updates. good first issue Standard label for new developers to locate good issues to tackle to learn about OCIO development.

Comments

@doug-walker
Copy link
Collaborator

The documentation on Contributing has some basic information about running the unit tests. However, it would be helpful to extend that to cover situations such as:

  • Running individual tests rather than all tests
  • Running only the CPU, GPU, or Python tests rather than all tests

For example, this will run only the CPU unit tests from the Builtins suite:
tests/cpu/test_cpu_exec --run_only Builtins

And this will run just Python test:
python3 ../tests/python/OpenColorIOTestSuite.py $PWD

@doug-walker doug-walker added Documentation Documentation related development and/or updates. good first issue Standard label for new developers to locate good issues to tackle to learn about OCIO development. labels Sep 22, 2023
@JaydenShel
Copy link

Can I take this?

@remia
Copy link
Collaborator

remia commented Feb 18, 2024

To just run one category of unit test, it might be simpler to stick with ctest:

# Get the list of tests
ctest -N
# Run individual tests examples
ctest -V -R test_cpu
ctest -V -R test_gpu
ctest -V -R test_python

But to reach individual tests within a group, I think we have to use our executable directly with --run_only like Doug showed.

@remia remia linked a pull request Feb 18, 2024 that will close this issue
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Documentation Documentation related development and/or updates. good first issue Standard label for new developers to locate good issues to tackle to learn about OCIO development.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants