(t *testing.T)
| 1030 | } |
| 1031 | |
| 1032 | func TestPrinterPrintBinaryIdentical(t *testing.T) { |
| 1033 | o := bytes.NewBufferString("") |
| 1034 | |
| 1035 | p := printer.NewPrinter(o) |
| 1036 | p.Print(&binary.Identical{ |
| 1037 | Left: &expr.Variable{ |
| 1038 | VarName: &node.Identifier{Value: "a"}, |
| 1039 | }, |
| 1040 | Right: &expr.Variable{ |
| 1041 | VarName: &node.Identifier{Value: "b"}, |
| 1042 | }, |
| 1043 | }) |
| 1044 | |
| 1045 | expected := `$a===$b` |
| 1046 | actual := o.String() |
| 1047 | |
| 1048 | if expected != actual { |
| 1049 | t.Errorf("\nexpected: %s\ngot: %s\n", expected, actual) |
| 1050 | } |
| 1051 | } |
| 1052 | |
| 1053 | func TestPrinterPrintBinaryLogicalAnd(t *testing.T) { |
| 1054 | o := bytes.NewBufferString("") |
nothing calls this directly
no test coverage detected
searching dependent graphs…