mirror of
https://github.com/cgrates/cgrates.git
synced 2026-02-16 05:39:54 +05:00
Added tests to utils
This commit is contained in:
committed by
Dan Christian Bogos
parent
27505075cc
commit
80ed8ae054
@@ -1112,3 +1112,14 @@ func TestIfaceAsDurationCaseFloat32(t *testing.T) {
|
||||
t.Errorf("Expected <9ns> ,received: <%+v>", response)
|
||||
}
|
||||
}
|
||||
|
||||
func TestIfaceAsStringInt32(t *testing.T) {
|
||||
var test int32
|
||||
var expected int64
|
||||
test = 2147483647
|
||||
expected = 2147483647
|
||||
response, _ := IfaceAsInt64(test)
|
||||
if !reflect.DeepEqual(response, expected) {
|
||||
t.Errorf("Expected <%+v> ,received: <%+v>", expected, response)
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user