llvm-capstone/lldb/lit/Reproducer/TestGDBRemoteRepro.test
Jonas Devlieghere a262531dd2 [Reproducers] Properly handle QEnvironment packets
On Linux, a QEnvironment packet is sent for every environment variable.
This breaks replay when the number of environment variables is different
then during capture. The solution is to always reply with OK.

llvm-svn: 356643
2019-03-21 04:08:31 +00:00

28 lines
970 B
Plaintext

# UNSUPPORTED: system-windows, system-freebsd
# This tests the replaying of GDB remote packets.
#
# We issue the same commands and ensure the output is identical to the original
# process. To ensure we're not actually running the original binary we check
# that the string "testing" is not printed.
# RUN: rm -rf %t.repro
# RUN: %clang %S/Inputs/simple.c -g -o %t.out
# RUN: %lldb -x -b -s %S/Inputs/GDBRemoteCapture.in --capture --capture-path %t.repro %t.out | FileCheck %s --check-prefix CHECK --check-prefix CAPTURE
# RUN: env FOO=BAR %lldb --replay %t.repro | FileCheck %s --check-prefix CHECK --check-prefix REPLAY
# CHECK: Breakpoint 1
# CHECK: Process {{.*}} stopped
# CHECK: Process {{.*}} launched
# CHECK: thread {{.*}} stop reason = breakpoint
# CHECK: frame {{.*}} simple.c
# CAPTURE: testing
# REPLAY-NOT: testing
# CHECK: Process {{.*}} resuming
# CHECK: Process {{.*}} exited
# CAPTURE: Reproducer is in capture mode.
# CAPTURE: Reproducer written