| 2419 | static int *SDK_ActionCancel_pstatus; |
| 2420 | |
| 2421 | int |
| 2422 | action_cancel_handler(TSCont contp, TSEvent event, void * /* edata ATS_UNUSED */) |
| 2423 | { |
| 2424 | if (event == TS_EVENT_IMMEDIATE) { // called from schedule_imm OK |
| 2425 | SDK_RPRINT(SDK_ActionCancel_test, "TSActionCancel", "TestCase1", TC_PASS, "ok"); |
| 2426 | *SDK_ActionCancel_pstatus = REGRESSION_TEST_PASSED; |
| 2427 | } else if (event == TS_EVENT_TIMEOUT) { // called from schedule_in Not OK. |
| 2428 | SDK_RPRINT(SDK_ActionCancel_test, "TSActionCancel", "TestCase1", TC_FAIL, "bad action"); |
| 2429 | *SDK_ActionCancel_pstatus = REGRESSION_TEST_FAILED; |
| 2430 | } else { // there is sth wrong |
| 2431 | SDK_RPRINT(SDK_ActionCancel_test, "TSActionCancel", "TestCase1", TC_FAIL, "bad event"); |
| 2432 | *SDK_ActionCancel_pstatus = REGRESSION_TEST_FAILED; |
| 2433 | } |
| 2434 | |
| 2435 | TSContDestroy(contp); |
| 2436 | return 0; |
| 2437 | } |
| 2438 | |
| 2439 | REGRESSION_TEST(SDK_API_TSActionCancel)(RegressionTest *test, int /* atype ATS_UNUSED */, int *pstatus) |
| 2440 | { |
nothing calls this directly
no test coverage detected