llvm-project/lldb/test/Shell/Breakpoint/breakpoint-command.test
cmtice efb0e9c0bd
[LLDB] Update breakpoint-command.test to use string instead of number. (#69796)
lldb/test/Shell/Breakpoint/breakpoint-command.test adds a python
command, to be executed when a breakpoint hits, that writes out a
number. It then runs, hits the breakpoint and checks that the number is
present exactly once.

The problem is that on some systems the test can be run in a filepath
that happens to contain the number (e.g. auto-generated directory
names). The number is then detected multiple times and the test fails.

This patch fixes the issue by using a string instead, particularly a
string with spaces, which is very unlikely to be auto-generated by any
system.
2023-10-22 15:42:55 -07:00

8 lines
256 B
Plaintext

# REQUIRES: lua || python
# RUN: %build %p/Inputs/dummy-target.c -o %t.out
# RUN: %lldb %t.out -o 'b main' -o 'break command add 1 -o "script print(\"A R4Nd0m\" + \" Str1ng\")"' -o 'r' | FileCheck %s
# CHECK: A R4Nd0m Str1ng
# CHECK-NOT: A R4Nd0m Str1ng