[docs] Reorder TESTING.md sections

And use --reconfigure where makes sense
pull/2657/head
ebraminio 5 years ago committed by GitHub
parent 1e48225ca3
commit 99b8a84cc5
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 42
      TESTING.md

@ -1,48 +1,46 @@
## Build & Run ## Build and Test
```shell
meson build
ninja -Cbuild
meson test -Cbuild
```
### Debug with GDB
```shell
meson test -Cbuild --gdb testname
```
## Build and Run
Depending on what area you are working in change or add `HB_DEBUG_<whatever>`. Depending on what area you are working in change or add `HB_DEBUG_<whatever>`.
Values defined in `hb-debug.hh`. Values defined in `hb-debug.hh`.
```shell ```shell
CPPFLAGS='-DHB_DEBUG_SUBSET=100' meson setup build CPPFLAGS='-DHB_DEBUG_SUBSET=100' meson setup build --reconfigure
meson test -C build meson test -C build
``` ```
### Run tests with asan ### Run tests with asan
```shell ```shell
meson setup build -Db_sanitize=address meson setup build -Db_sanitize=address --reconfigure
meson compile -C build meson compile -C build
meson test -C build meson test -C build
``` ```
### Debug with GDB
```
meson setup build
meson compile -C build
meson test -C build --gdb testname
```
### Enable Debug Logging ### Enable Debug Logging
```shell ```shell
CPPFLAGS=-DHB_DEBUG_SUBSET=100 meson build CPPFLAGS=-DHB_DEBUG_SUBSET=100 meson build --reconfigure
ninja -C build ninja -C build
``` ```
## Build and Test
```shell
meson build
ninja -Cbuild
meson test -Cbuild
```
## Test with the Fuzzer ## Test with the Fuzzer
```shell ```shell
CXXFLAGS="-fsanitize=address,fuzzer-no-link" meson build --default-library=static -Dfuzzer_ldflags="-fsanitize=address,fuzzer" -Dexperimental_api=true CXXFLAGS="-fsanitize=address,fuzzer-no-link" meson build --default-library=static -Dfuzzer_ldflags="-fsanitize=address,fuzzer" -Dexperimental_api=true --reconfigure
ninja -C build test/fuzzing/hb-{shape,draw,subset,set}-fuzzer ninja -C build test/fuzzing/hb-{shape,draw,subset,set}-fuzzer
build/test/fuzzing/hb-subset-fuzzer build/test/fuzzing/hb-subset-fuzzer
``` ```
@ -50,7 +48,7 @@ build/test/fuzzing/hb-subset-fuzzer
## Profiling ## Profiling
``` ```
meson build meson build --reconfigure
meson compile -C build meson compile -C build
build/perf/perf build/perf/perf
``` ```

Loading…
Cancel
Save