]> Cypherpunks repositories - gostls13.git/commitdiff
If we can't parse the package, call Fatalf so that the test
authorIan Lance Taylor <iant@golang.org>
Fri, 24 Jul 2009 20:07:12 +0000 (13:07 -0700)
committerIan Lance Taylor <iant@golang.org>
Fri, 24 Jul 2009 20:07:12 +0000 (13:07 -0700)
fails without crashing.

R=gri
DELTA=1  (0 added, 0 deleted, 1 changed)
OCL=32164
CL=32171

src/pkg/go/parser/parser_test.go

index 3b02c503453d754eb254ac7dd2f3e478ac85d442..b6618d06e83c2174d5408e04fafd4cf0063e5cab 100644 (file)
@@ -78,7 +78,7 @@ func TestParse4(t *testing.T) {
        path := ".";
        pkg, err := ParsePackage(path, filter, 0);
        if err != nil {
-               t.Errorf("ParsePackage(%s): %v", path, err);
+               t.Fatalf("ParsePackage(%s): %v", path, err);
        }
        if pkg.Name != "parser" {
                t.Errorf("incorrect package name: %s", pkg.Name);