mirror of
https://github.com/cgrates/cgrates.git
synced 2026-02-11 18:16:24 +05:00
local tests fixes for rounding movement
This commit is contained in:
@@ -286,7 +286,7 @@ func TestApierTPRate(t *testing.T) {
|
||||
}
|
||||
reply := ""
|
||||
rt := &utils.TPRate{TPid: engine.TEST_SQL, RateId: "RT_FS_USERS", RateSlots: []*utils.RateSlot{
|
||||
&utils.RateSlot{ConnectFee: 0, Rate: 0, RateUnit: "60s", RateIncrement: "60s", GroupIntervalStart: "0s", RoundingMethod: "*up", RoundingDecimals: 0},
|
||||
&utils.RateSlot{ConnectFee: 0, Rate: 0, RateUnit: "60s", RateIncrement: "60s", GroupIntervalStart: "0s"},
|
||||
}}
|
||||
rt2 := new(utils.TPRate)
|
||||
*rt2 = *rt
|
||||
|
||||
@@ -1,3 +1,3 @@
|
||||
#Tag,DestinationsTag,RatesTag
|
||||
#Tag,DestinationsTag,RatesTag,RoundingMethod,RoundingDecimals
|
||||
DR_RETAIL,GERMANY,RT_1CENT,*up,2
|
||||
DR_RETAIL,GERMANY_MOBILE,RT_1CENT,*up,2
|
||||
|
||||
|
@@ -1,2 +1,2 @@
|
||||
#Tag,ConnectFee,Rate,RateUnit,RateIncrement,GroupIntervalStart,RoundingMethod,RoundingDecimals
|
||||
#Tag,ConnectFee,Rate,RateUnit,RateIncrement,GroupIntervalStart
|
||||
RT_1CENT,0,1,1s,1s,0s
|
||||
|
||||
|
@@ -184,7 +184,7 @@ var FileValidators = map[string]*FileLineRegexValidator{
|
||||
regexp.MustCompile(`(?:\w+\s*,\s*){1}(?:\d+\.?\d*,){2}(?:\d+s*,?){3}$`),
|
||||
"Tag([0-9A-Za-z_]),ConnectFee([0-9.]),Rate([0-9.]),RateUnit([0-9.]),RateIncrementStart([0-9.])"},
|
||||
utils.DESTINATION_RATES_CSV: &FileLineRegexValidator{utils.DESTINATION_RATES_NRCOLS,
|
||||
regexp.MustCompile(`^(?:\w+\s*),(?:\w+\s*),(?:\w+\s*)$`),
|
||||
regexp.MustCompile(`^(?:\w+\s*),(?:\w+\s*),(?:\w+\s*),(?:\w+\s*)(?:\*\w+,){1}(?:\d+\.?\d*,?){1}$`),
|
||||
"Tag([0-9A-Za-z_]),DestinationsTag([0-9A-Za-z_]),RateTag([0-9A-Za-z_])"},
|
||||
utils.RATING_PLANS_CSV: &FileLineRegexValidator{utils.DESTRATE_TIMINGS_NRCOLS,
|
||||
regexp.MustCompile(`(?:\w+\s*,\s*){3}(?:\d+.?\d*){1}$`),
|
||||
|
||||
@@ -45,7 +45,7 @@ DUMMY,INVALID;DATA
|
||||
`
|
||||
|
||||
var destRatesSample = `#Tag,DestinationsTag,RatesTag
|
||||
DR_RETAIL,GERMANY,RT_1CENT
|
||||
DR_RETAIL,GERMANY,RT_1CENT,*up,0
|
||||
DUMMY,INVALID;DATA
|
||||
`
|
||||
var ratingPlansSample = `#Tag,DestinationRatesTag,TimingTag,Weight
|
||||
|
||||
Reference in New Issue
Block a user