Fix the tests

This commit is contained in:
Dmitry
2023-08-25 10:36:03 +02:00
committed by quobix
parent 6ce66d7f32
commit 2042152318
79 changed files with 735 additions and 735 deletions

View File

@@ -33,7 +33,7 @@ func TestCallback_Build_Success(t *testing.T) {
err := low.BuildModel(rootNode.Content[0], &n)
assert.NoError(t, err)
err = n.Build(rootNode.Content[0], nil)
err = n.Build(nil, rootNode.Content[0], nil)
assert.NoError(t, err)
assert.Len(t, n.Expression.Value, 1)
@@ -65,7 +65,7 @@ func TestCallback_Build_Error(t *testing.T) {
err := low.BuildModel(rootNode.Content[0], &n)
assert.NoError(t, err)
err = n.Build(rootNode.Content[0], idx)
err = n.Build(nil, rootNode.Content[0], idx)
assert.Error(t, err)
}
@@ -100,7 +100,7 @@ func TestCallback_Build_Using_InlineRef(t *testing.T) {
err := low.BuildModel(rootNode.Content[0], &n)
assert.NoError(t, err)
err = n.Build(rootNode.Content[0], idx)
err = n.Build(nil, rootNode.Content[0], idx)
assert.NoError(t, err)
assert.Len(t, n.Expression.Value, 1)
@@ -128,7 +128,7 @@ x-weed: loved`
var n Callback
_ = low.BuildModel(idxNode.Content[0], &n)
_ = n.Build(idxNode.Content[0], idx)
_ = n.Build(nil, idxNode.Content[0], idx)
yml2 := `burgers:
description: tasty!
@@ -145,7 +145,7 @@ beer:
var n2 Callback
_ = low.BuildModel(idxNode2.Content[0], &n2)
_ = n2.Build(idxNode2.Content[0], idx2)
_ = n2.Build(nil, idxNode2.Content[0], idx2)
// hash
assert.Equal(t, n.Hash(), n2.Hash())