mirror of
https://github.com/cgrates/cgrates.git
synced 2026-02-11 18:16:24 +05:00
coverage tests at engine
This commit is contained in:
committed by
Dan Christian Bogos
parent
4305c505a8
commit
e7520002eb
@@ -20,6 +20,7 @@ package engine
|
||||
|
||||
import (
|
||||
"fmt"
|
||||
"reflect"
|
||||
"testing"
|
||||
"time"
|
||||
|
||||
@@ -215,3 +216,27 @@ func TestCDRSV1V1ProcessExternalCDRNoTenant(t *testing.T) {
|
||||
t.Error(err)
|
||||
}
|
||||
}
|
||||
|
||||
func TestArgV1ProcessClone(t *testing.T) {
|
||||
attr := &ArgV1ProcessEvent{
|
||||
Flags: []string{"flg,flg2,flg3"},
|
||||
CGREvent: utils.CGREvent{
|
||||
ID: "TestBiRPCv1AuthorizeEventNoTenant",
|
||||
Time: utils.TimePointer(time.Date(2016, time.January, 5, 18, 30, 49, 0, time.UTC)),
|
||||
Event: map[string]interface{}{
|
||||
"Account": "1002",
|
||||
"Category": "call",
|
||||
"Destination": "1003",
|
||||
"OriginHost": "local",
|
||||
"OriginID": "123456",
|
||||
"ToR": "*voice",
|
||||
"Usage": "10s",
|
||||
},
|
||||
},
|
||||
clnb: true,
|
||||
}
|
||||
if val := attr.Clone(); reflect.DeepEqual(attr, val) {
|
||||
t.Errorf("expected %v,received %v", utils.ToJSON(val), utils.ToJSON(attr))
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user