Skip to content

Commit 88b61c9

Browse files
committed
Simplify TestMessageString
1 parent 26c745a commit 88b61c9

File tree

1 file changed

+4
-7
lines changed

1 file changed

+4
-7
lines changed

message_test.go

Lines changed: 4 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -16,23 +16,20 @@ package thriftcheck
1616

1717
import (
1818
"testing"
19-
20-
"go.uber.org/thriftrw/ast"
2119
)
2220

2321
func TestMessageString(t *testing.T) {
24-
node := &ast.Struct{}
2522
tests := []struct {
2623
m *Message
2724
s string
2825
}{
2926
{
30-
&Message{Filename: "a.thrift", Node: node, Check: "check", Severity: Warning, Message: "Warning"},
31-
"a.thrift:0:1:warning: Warning (check)",
27+
&Message{Filename: "a.thrift", Line: 5, Check: "check", Severity: Warning, Message: "Warning"},
28+
"a.thrift:5:1:warning: Warning (check)",
3229
},
3330
{
34-
&Message{Filename: "a.thrift", Node: node, Check: "check", Severity: Error, Message: "Error"},
35-
"a.thrift:0:1:error: Error (check)",
31+
&Message{Filename: "a.thrift", Line: 5, Check: "check", Severity: Error, Message: "Error"},
32+
"a.thrift:5:1:error: Error (check)",
3633
},
3734
}
3835

0 commit comments

Comments
 (0)