github.com/euank/go@v0.0.0-20160829210321-495514729181/src/cmd/compile/internal/syntax/dumper_test.go (about)

     1  // Copyright 2016 The Go Authors. All rights reserved.
     2  // Use of this source code is governed by a BSD-style
     3  // license that can be found in the LICENSE file.
     4  
     5  package syntax
     6  
     7  import (
     8  	"os"
     9  	"testing"
    10  )
    11  
    12  func TestDump(t *testing.T) {
    13  	if testing.Short() {
    14  		t.Skip("skipping test in short mode")
    15  	}
    16  
    17  	ast, err := ReadFile(*src, nil, 0)
    18  	if err != nil {
    19  		t.Fatal(err)
    20  	}
    21  	Fdump(os.Stdout, ast)
    22  }