From c112d1dcf0d942f772d924a6b163194111143760 Mon Sep 17 00:00:00 2001 From: z7zmey Date: Thu, 8 Feb 2018 23:31:38 +0200 Subject: [PATCH] If tests --- node/stmt/t_if_test.go | 146 +++++++++++++++++++++++++++++++++++++++++ php5/php5.go | 2 +- php5/php5.y | 2 +- 3 files changed, 148 insertions(+), 2 deletions(-) create mode 100644 node/stmt/t_if_test.go diff --git a/node/stmt/t_if_test.go b/node/stmt/t_if_test.go new file mode 100644 index 0000000..ff7c158 --- /dev/null +++ b/node/stmt/t_if_test.go @@ -0,0 +1,146 @@ +package stmt_test + +import ( + "bytes" + "testing" + + "github.com/z7zmey/php-parser/node/expr" + + "github.com/z7zmey/php-parser/node" + "github.com/z7zmey/php-parser/node/stmt" + "github.com/z7zmey/php-parser/php5" + "github.com/z7zmey/php-parser/php7" +) + +func TestIf(t *testing.T) { + src := `