mirror of
https://github.com/cgrates/cgrates.git
synced 2026-02-25 00:58:45 +05:00
Renamed *string_prefix -> *stringprefix
This commit is contained in:
committed by
Dan Christian Bogos
parent
bd80a00109
commit
64f32a216e
@@ -168,7 +168,7 @@ func testFilterUpdateFilter(t *testing.T) {
|
||||
Values: []string{"1001", "1002"},
|
||||
},
|
||||
&engine.RequestFilter{
|
||||
FieldName: "*string_prefix",
|
||||
FieldName: "*stringprefix",
|
||||
Type: "Destination",
|
||||
Values: []string{"10", "20"},
|
||||
},
|
||||
|
||||
@@ -179,7 +179,7 @@ func testTPFilterUpdateTPFilter(t *testing.T) {
|
||||
Values: []string{"1001", "1002"},
|
||||
},
|
||||
&utils.TPFilter{
|
||||
Type: "*string_prefix",
|
||||
Type: "*stringprefix",
|
||||
FieldName: "Destination",
|
||||
Values: []string{"10", "20"},
|
||||
},
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
#Tenant[0],ID[1],FilterType[2],FilterFieldName[3],FilterFieldValues[4],ActivationInterval[5]
|
||||
cgrates.org,FLTR_1,*string,Account,1001;1002,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_1,*string_prefix,Destination,10;20,
|
||||
cgrates.org,FLTR_1,*stringprefix,Destination,10;20,
|
||||
cgrates.org,FLTR_1,*rsr,,Subject(~^1.*1$);Destination(1002),
|
||||
cgrates.org,FLTR_ACNT_1007,*string,Account,1007,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_ACNT_dan,*string,Account,dan,2014-07-29T15:00:00Z
|
||||
|
||||
|
@@ -1,6 +1,6 @@
|
||||
#Tenant[0],ID[1],FilterType[2],FilterFieldName[3],FilterFieldValues[4],ActivationInterval[5]
|
||||
cgrates.org,FLTR_1,*string,Account,1001;1002,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_1,*string_prefix,Destination,10;20,
|
||||
cgrates.org,FLTR_1,*stringprefix,Destination,10;20,
|
||||
cgrates.org,FLTR_1,*rsr,,Subject(~^1.*1$);Destination(1002),
|
||||
cgrates.org,FLTR_ACNT_1007,*string,Account,1007,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_ACNT_dan,*string,Account,dan,2014-07-29T15:00:00Z
|
||||
|
||||
|
@@ -31,7 +31,7 @@ import (
|
||||
|
||||
const (
|
||||
MetaString = "*string"
|
||||
MetaStringPrefix = "*string_prefix"
|
||||
MetaStringPrefix = "*stringprefix"
|
||||
MetaTimings = "*timings"
|
||||
MetaRSR = "*rsr"
|
||||
MetaStatS = "*stats"
|
||||
|
||||
@@ -307,13 +307,13 @@ func TestInlineFilterPassFiltersForEvent(t *testing.T) {
|
||||
"Account": "1007",
|
||||
}
|
||||
if pass, err := filterS.PassFiltersForEvent("cgrates.org",
|
||||
failEvent, []string{"*string_prefix:Account:10"}); err != nil {
|
||||
failEvent, []string{"*stringprefix:Account:10"}); err != nil {
|
||||
t.Errorf(err.Error())
|
||||
} else if pass {
|
||||
t.Errorf("Expecting: %+v, received: %+v", false, pass)
|
||||
}
|
||||
if pass, err := filterS.PassFiltersForEvent("cgrates.org",
|
||||
passEvent, []string{"*string_prefix:Account:10"}); err != nil {
|
||||
passEvent, []string{"*stringprefix:Account:10"}); err != nil {
|
||||
t.Errorf(err.Error())
|
||||
} else if !pass {
|
||||
t.Errorf("Expecting: %+v, received: %+v", true, pass)
|
||||
|
||||
@@ -284,7 +284,7 @@ cgrates.org,Threshold1,FLTR_1;FLTR_ACNT_dan,2014-07-29T15:00:00Z,true,10,1s,true
|
||||
filters = `
|
||||
#Tenant[0],ID[1],FilterType[2],FilterFieldName[3],FilterFieldValues[4],ActivationInterval[5]
|
||||
cgrates.org,FLTR_1,*string,Account,1001;1002,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_1,*string_prefix,Destination,10;20,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_1,*stringprefix,Destination,10;20,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_1,*rsr,,Subject(~^1.*1$);Destination(1002),
|
||||
cgrates.org,FLTR_ACNT_dan,*string,Account,dan,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_DST_DE,*destinations,Destination,DST_DE,2014-07-29T15:00:00Z
|
||||
@@ -1564,7 +1564,7 @@ func TestLoadFilters(t *testing.T) {
|
||||
},
|
||||
&utils.TPFilter{
|
||||
FieldName: "Destination",
|
||||
Type: "*string_prefix",
|
||||
Type: "*stringprefix",
|
||||
Values: []string{"10", "20"},
|
||||
},
|
||||
&utils.TPFilter{
|
||||
|
||||
Reference in New Issue
Block a user