mirror of
https://gitlab.com/pulsechaincom/go-pulse.git
synced 2024-12-28 14:27:16 +00:00
32 lines
308 B
Go
32 lines
308 B
Go
package ethutil
|
|
|
|
import (
|
|
"fmt"
|
|
"testing"
|
|
)
|
|
|
|
func TestPreProcess(t *testing.T) {
|
|
main, init := PreProcess(`
|
|
init {
|
|
// init
|
|
if a > b {
|
|
if {
|
|
}
|
|
}
|
|
}
|
|
|
|
main {
|
|
// main
|
|
if a > b {
|
|
if c > d {
|
|
}
|
|
}
|
|
}
|
|
`)
|
|
|
|
fmt.Println("main")
|
|
fmt.Println(main)
|
|
fmt.Println("init")
|
|
fmt.Println(init)
|
|
}
|