diff --git a/doc/debugging.md b/doc/debugging.md index 23f4583a7..3d3c79768 100644 --- a/doc/debugging.md +++ b/doc/debugging.md @@ -87,21 +87,14 @@ Renderdoc is usually the better tool to debug something with, but it's also hard dnf install -y gdb ``` -4. Replicate a environment and run the test inside gdb. What you need here depends on the test that needs investigation. In the simplest case, the following is enough: +4. Run the test case + + ```sh + meson test -C build failing-test-case + ``` + +5. Run the test case in gdb ```sh - export XDG_RUNTIME_DIR=$PWD/runtime-dir - mkdir -p $XDG_RUNTIME_DIR ./src/tests/meta-dbus-runner.py meson test -C build --setup plain --gdb failing-test-case ``` - - If it involves screen casting, it becomes a bit more complicated: - - ```sh - export XDG_RUNTIME_DIR=$PWD/runtime-dir - mkdir -p $XDG_RUNTIME_DIR - ./src/tests/meta-dbus-runner.py bash -l - pipewire& - wireplumber& - meson test -C build --setup plain --gdb failing-test-case - ```