Added overloaded support for str * int
This commit is contained in:
@@ -10,7 +10,7 @@ import (
|
||||
"testing"
|
||||
)
|
||||
|
||||
func TestEvalIntegerExpression(t *testing.T) {
|
||||
func TestEvalExpressions(t *testing.T) {
|
||||
tests := []struct {
|
||||
input string
|
||||
expected interface{}
|
||||
@@ -36,6 +36,8 @@ func TestEvalIntegerExpression(t *testing.T) {
|
||||
{"1 | 2", 3},
|
||||
{"2 ^ 4", 6},
|
||||
{"3 & 6", 2},
|
||||
{`" " * 4`, " "},
|
||||
{`4 * " "`, " "},
|
||||
}
|
||||
|
||||
for _, tt := range tests {
|
||||
|
||||
Reference in New Issue
Block a user