| 1 | // Purpose: |
| 2 | // Check that \DexExpectStepKind correctly counts 'FUNC' steps for a |
| 3 | // trivial test. Expect one 'FUNC' per call to a function which is defined |
| 4 | // in one of the source files in the test directory. |
| 5 | // |
| 6 | // UNSUPPORTED: system-darwin |
| 7 | // |
| 8 | // RUN: %dexter_regression_test_cxx_build %s -o %t |
| 9 | // RUN: %dexter_regression_test_run --binary %t -- %s | FileCheck %s |
| 10 | // CHECK: func.cpp: |
| 11 | |
| 12 | int func(int i) { |
| 13 | return i; |
| 14 | } |
| 15 | |
| 16 | int main() |
| 17 | { |
| 18 | func(i: 0); |
| 19 | func(i: 1); |
| 20 | return 0; |
| 21 | } |
| 22 | |
| 23 | // main, func, func |
| 24 | // DexExpectStepKind('FUNC', 3) |
| 25 | |