php-parser/node/t_position_test.go
2019-03-20 21:06:56 +02:00

19 lines
314 B
Go

package node_test
import (
"testing"
"gotest.tools/assert"
"github.com/z7zmey/php-parser/position"
)
func TestPosition(t *testing.T) {
expected := position.NewPosition(1, 1, 0, 1)
for _, n := range nodes {
n.SetPosition(expected)
actual := n.GetPosition()
assert.DeepEqual(t, expected, actual)
}
}