aboutsummaryrefslogtreecommitdiff
path: root/driver/parser/conflict_test.go
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--driver/parser/conflict_test.go (renamed from driver/conflict_test.go)13
1 files changed, 4 insertions, 9 deletions
diff --git a/driver/conflict_test.go b/driver/parser/conflict_test.go
index 3b0c5fb..21b829a 100644
--- a/driver/conflict_test.go
+++ b/driver/parser/conflict_test.go
@@ -1,11 +1,11 @@
-package driver
+package parser
import (
"strings"
"testing"
"github.com/nihei9/vartan/grammar"
- spec "github.com/nihei9/vartan/spec/grammar"
+ "github.com/nihei9/vartan/spec/grammar/parser"
)
func TestParserWithConflicts(t *testing.T) {
@@ -486,7 +486,7 @@ assign: '=';
for _, tt := range tests {
t.Run(tt.caption, func(t *testing.T) {
- ast, err := spec.Parse(strings.NewReader(tt.specSrc))
+ ast, err := parser.Parse(strings.NewReader(tt.specSrc))
if err != nil {
t.Fatal(err)
}
@@ -494,12 +494,7 @@ assign: '=';
b := grammar.GrammarBuilder{
AST: ast,
}
- g, err := b.Build()
- if err != nil {
- t.Fatal(err)
- }
-
- cg, _, err := grammar.Compile(g)
+ cg, _, err := b.Build()
if err != nil {
t.Fatal(err)
}