/***************************************************
   1. Trigger ICM to load PS plugin
   2. Create PS MT call
   3. Answer call
   4. Hangup call by remote
***************************************************/

[StifSettings]
CheckHeapBalance= on
[EndStifSettings]

[Test]
title 3.2 MT call, Hangup by Originator
timeout 15000
create ccetester test
test Delay 1000

// Step 1
print Step_1

test InitIncomingCall

// Wait plugin to initialize
test Delay 1000

// Step 2
print Step_2

// Send plugin command, MT call with CallID 1 is created
test SendPluginRequest CreateCall 2
test WaitEvent 0 IncomingCall
test WaitEvent 1 Ringing

// Step 3
print Step_3

// Answer call
test Answer 1 0
test WaitEvent 1 Answering
test WaitEvent 1 Connected

// Step 4
print Step_4

// Hangup by plugin
test SendPluginRequest HangupCall 1
test WaitEvent 1 RemoteTerminated
test WaitEvent 1 Disconnecting
test WaitEvent 1 Idle
test Release 1 0

test VerifyTest
delete test
[Endtest] 
