Coverage tests in console

This commit is contained in:
andronache
2021-01-29 12:35:29 +02:00
committed by Dan Christian Bogos
parent 6ce6cbc47d
commit 6b4b92545d
3 changed files with 127 additions and 1 deletions

View File

@@ -19,6 +19,8 @@ along with this program. If not, see <http://www.gnu.org/licenses/>
package console
import (
"fmt"
"github.com/cgrates/cgrates/config"
"github.com/cgrates/cgrates/utils"
)
@@ -77,6 +79,7 @@ func (self *CmdParse) LocalExecute() string {
if rsrField, err := config.NewRSRParser(self.rpcParams.Expression); err != nil {
return err.Error()
} else if parsed, err := rsrField.ParseValue(self.rpcParams.Value); err != nil {
fmt.Println("yay")
return err.Error()
} else {
return parsed