master > master: codego - utils + unit tests, A1[0-9]+ mit testen

This commit is contained in:
RD
2021-05-18 11:32:32 +02:00
parent 2ab9b63a08
commit f292d7e5dc
4 changed files with 38 additions and 17 deletions

View File

@@ -205,8 +205,7 @@ func TestAtomsCalc1(test *testing.T) {
var val []string
fml = schema.ParseExpr("A0")
val = recursion.Atoms(fml)
utils.SortStrings(&val)
assert.Equal([]string{"A0"}, val)
assert.ElementsMatch([]string{"A0"}, val)
}
func TestAtomsCalc2(test *testing.T) {
@@ -216,8 +215,7 @@ func TestAtomsCalc2(test *testing.T) {
var val []string
fml = schema.ParseExpr("((( ! A8 && A3 ) || A4 ) && A0 )")
val = recursion.Atoms(fml)
utils.SortStrings(&val)
assert.Equal([]string{"A0", "A3", "A4", "A8"}, val)
assert.ElementsMatch([]string{"A0", "A3", "A4", "A8"}, val)
}
/* ---------------------------------------------------------------- *