diff --git a/general_tests/tutorial_kam_calls_test.go b/general_tests/tutorial_kam_calls_test.go index 12ce0cfb9..0cade7da6 100644 --- a/general_tests/tutorial_kam_calls_test.go +++ b/general_tests/tutorial_kam_calls_test.go @@ -411,7 +411,7 @@ func TestTutKamCalls1002Cdrs(t *testing.T) { req := utils.RpcCdrsFilter{Accounts: []string{"1002"}, RunIds: []string{utils.META_DEFAULT}} if err := tutKamCallsRpc.Call("ApierV2.GetCdrs", req, &reply); err != nil { t.Error("Unexpected error: ", err.Error()) - } else if len(reply) != 1 { + } else if len(reply) != 2 { t.Error("Unexpected number of CDRs returned: ", len(reply)) } else { if reply[0].CdrSource != "KAMAILIO_CGR_CALL_END" { @@ -494,24 +494,8 @@ func TestTutKamCalls1006Cdrs(t *testing.T) { req := utils.RpcCdrsFilter{Accounts: []string{"1006"}, RunIds: []string{utils.META_DEFAULT}} if err := tutKamCallsRpc.Call("ApierV2.GetCdrs", req, &reply); err != nil { t.Error("Unexpected error: ", err.Error()) - } else if len(reply) != 1 { + } else if len(reply) != 0 { t.Error("Unexpected number of CDRs returned: ", len(reply)) - } else { - if reply[0].CdrSource != "KAMAILIO_CGR_CALL_END" { - t.Errorf("Unexpected CdrSource for CDR: %+v", reply[0]) - } - if reply[0].ReqType != utils.META_PREPAID { - t.Errorf("Unexpected ReqType for CDR: %+v", reply[0]) - } - if reply[0].Destination != "1002" { - t.Errorf("Unexpected Destination for CDR: %+v", reply[0]) - } - if reply[0].Usage != "64" && reply[0].Usage != "65" { // Usage as seconds - t.Errorf("Unexpected Usage for CDR: %+v", reply[0]) - } - if reply[0].Cost == -1.0 { // Cost was not calculated - t.Errorf("Unexpected Cost for CDR: %+v", reply[0]) - } } }