This commit is contained in:
parent
64a80f6090
commit
e6a6be1181
4 changed files with 43 additions and 49 deletions
23
src/linker/Write_test.go
Normal file
23
src/linker/Write_test.go
Normal file
|
@ -0,0 +1,23 @@
|
|||
package linker_test
|
||||
|
||||
import (
|
||||
"testing"
|
||||
|
||||
"git.urbach.dev/cli/q/src/build"
|
||||
"git.urbach.dev/cli/q/src/compiler"
|
||||
"git.urbach.dev/cli/q/src/exe"
|
||||
"git.urbach.dev/cli/q/src/linker"
|
||||
"git.urbach.dev/go/assert"
|
||||
)
|
||||
|
||||
func TestWrite(t *testing.T) {
|
||||
b := build.New("../../examples/hello")
|
||||
|
||||
b.Matrix(func(b *build.Build) {
|
||||
env, err := compiler.Compile(b)
|
||||
assert.Nil(t, err)
|
||||
|
||||
writer := &exe.Discard{}
|
||||
linker.Write(writer, b, env)
|
||||
})
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue