Skip to content

Commit

Permalink
Add information on running tests (#796)
Browse files Browse the repository at this point in the history
Co-authored-by: SpyCheese <[email protected]>
  • Loading branch information
EmelyanenkoK and SpyCheese authored Nov 3, 2023
1 parent 52fd824 commit 79ed14c
Show file tree
Hide file tree
Showing 2 changed files with 25 additions and 1 deletion.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -70,4 +70,4 @@ If a CI workflow fails not because of your changes but workflow issues, try to f

## Running tests

Tests are executed by running `ctest` in the build directory.
Tests are executed by running `ctest` in the build directory. See `doc/Tests.md` for more information.
24 changes: 24 additions & 0 deletions doc/Tests.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
# Tests execution
TON contains multiple unit-tests, that facilitate detection of erroneous blockchain behaviour on each commit.
## Build tests
Go inside the build directory and, if you use ninja, build the tests using the following command:

```ninja test-ed25519 test-ed25519-crypto test-bigint test-vm test-fift test-cells test-smartcont test-net test-tdactor test-tdutils test-tonlib-offline test-adnl test-dht test-rldp test-rldp2 test-catchain test-fec test-tddb test-db test-validator-session-state```

For more details on how to build TON artifacts, please refer to any of Github actions.

For cmake use:

```cmake --build . --target test-ed25519 test-ed25519-crypto test-bigint test-vm test-fift test-cells test-smartcont test-net test-tdactor test-tdutils test-tonlib-offline test-adnl test-dht test-rldp test-rldp2 test-catchain test-fec test-tddb test-db test-validator-session-state```

## Run tests
Go inside the build directory and with ninja execute:

```ninja test```

with ctest:

```ctest```

## Integration of tests into CI
Most relevant GitHub actions include the step ```Run tests``` that executes the tests. If any of tests fails, the action will be interrupted and no artifacts will be provided.

0 comments on commit 79ed14c

Please sign in to comment.