compiler: provide .go
filename to Compile
First argument contains filename, thus we use '.go' suffix to distinguish between directories and files. Contract name should be provided in options. Signed-off-by: Evgeniy Stratonikov <evgeniy@nspcc.ru>
This commit is contained in:
parent
8af9c870b1
commit
e7a0ecb349
10 changed files with 35 additions and 28 deletions
|
@ -139,7 +139,7 @@ func runSyscallTestCase(t *testing.T, ic *interop.Context, goName string, tc sys
|
|||
}
|
||||
ss := strings.Split(goName, ".")
|
||||
src := fmt.Sprintf(srcTmpl, ss[0], goName, strings.Join(tc.params, ", "))
|
||||
b, _, err := compiler.CompileWithOptions("foo", strings.NewReader(src), nil)
|
||||
b, _, err := compiler.CompileWithOptions("foo.go", strings.NewReader(src), nil)
|
||||
require.NoError(t, err)
|
||||
|
||||
v := ic.SpawnVM()
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue