Skip to content
spenke91 edited this page Jan 20, 2026 · 4 revisions

We collect general tips and tricks for t8code developers.

Try setting the T8CODE_TEST_LEVEL to a higher number (for example, 2) to make the test suite faster.

Compiling and running individual tests

When writing a new test, you do not have to run make test every time to compile your single test. make test will compile and run all tests which is rather time consuming.

Instead you can compile and run your tests individually:

make test/path/to/test
./test/path/to/test

Attention: Individual tests using testfiles from the test/testfiles folder must be run from the build/test/ folder. This ensures that the paths specified are valid.

Locally reproduce the CI behaviour using podman

The free and open-source container tool podman allows you to locally work with our CI docker images. This way, you can reproduce the CI behavior or even try and debug compilation, execution, etc. in interactive mode.

Here is how it works:

  1. Pull a docker imageof our CI via podman pull <image_name>, for example

    podman pull dlramr/t8code-ubuntu:t8-dependencies`
    
  2. To enter it in interactive mode, you can use podman run . Note that the images themselves don't contain the t8code repository yet. To add it to the same path the CI does, it's simplest to run

    podman run --rm -it   -v "$(pwd):/_w/t8code"   -w "/_w/t8code"   dlramr/t8code-ubuntu:t8-dependencies   /bin/bash
    

    either (a) from an empty folder and then clone t8code into /_w/t8code/t8code, or (b) from a folder already containing a subfolder t8code with the git repository.

  3. Now you are in the docker image used by the CI and free to do anything in the terminal. In the Github workflow files, you can find the steps of the CI proecedures in case you want to run those.

Deactivating sc and p4est tests

If you are developing and running make test often, waiting for sc and p4est tests to compile and run can be tedious. Especially since you do not change anything in sc and p4est and hence know that the test cases will pass. Set the T8CODE_BUILD_TPL_TESTS option to OFF to disable third party library tests.

Clone this wiki locally