16 lines
273 B
Go
16 lines
273 B
Go
package goast
|
|
|
|
import (
|
|
"fmt"
|
|
"github.com/stretchr/testify/assert"
|
|
"testing"
|
|
)
|
|
|
|
func TestParser_Parse(t *testing.T) {
|
|
parser, err := NewParser("./example.go")
|
|
assert.NoError(t, err)
|
|
defines, err := parser.Parse()
|
|
assert.NoError(t, err)
|
|
fmt.Printf("%+v", defines)
|
|
}
|