Debugger Breakpoints, Conditions and Hit Count functionality

References
Purpose:

To test that conditional breakpoints and hit count functionality perform as expected

Test procedure:

1) Set a breakpoint at the line i := i + 1', run the system, it should stop on every i increment. Remove the breakpoint and make sure that the application runs without stopping.

2) Add a conditional breakpoint and set it to 'i \\ 50 = 0' with the 'Is True' condition set, the debugger should stop when i is 0, 50.... up to 1000 (20 times). Remove the condition and make sure that the application runs without stopping.

3) Perform test 3 but with 'Has Changed' set for the condition. Debugger should stop at 0, 1, 50, 51......up to 1000 (40 times)

4) Repeat tests 1 to 3 but with the condition using 'i_str.to_integer :=' instead of 'i :='

5) Repeat test 1 with the various hit count break settings (Always, Break when the hit count equals (-1, 0, 50, 1000, 1001, {INTEGER}.max + 1), Break when a multiple of (-1, 0, 50, 1000, 1001, {INTEGER}.max + 1), Break when the hit count is greater than (-1, 0, 50, 1001, {INTEGER}.max + 1) to make sure that it breaks appropriately. Make sure that Reset actually resets the hit count.

6) Repeat test 2 but also use the 'When hits' functionality, checking that the output in the Output pane is displayed correctly for the following strings

  • 'HitCount $HITCOUNT of Value {i} for Call $CALL'
  • 'Thread $THREADID' -- Check that the THREADID is 1 for mono-threaded and valid values when multi-threaded.
  • 'CallStack $CALLSTACK'
  • 'Class $CLASS Feature $FEATURE'
  • 'Current Call = $CALL'
  • 'Address $ADDRESS'

7) Change the last loop in the code so that the condition reads 'j > 5', this will launch 5 threads, check that multiple threads work for tests 1 to 6, the total hitcount value should be the number of hits for each thread multiplied by the number of threads. Also make sure that the $THREADID is for the appropriate thread.

Initial Conditions:

Compile the attached files (in both single and multi-threaded modes) on 32/64 bit platforms on both Windows and Linux.

Expected result:

Results are mentioned next to the tests

AttachmentSize
debugger_breakpoints_test_mono_threaded.ecf1.17 KB
debugger_breakpoints_test_mono_threaded.e832 bytes

Test runs

IDDatePlatformResult
trr#2991 year 11 weeks agoAll platformsPassed