mirror of
https://github.com/yggdrasil-network/water.git
synced 2025-05-19 16:35:10 +03:00
rename test files (fix https://github.com/songgao/water/issues/4)
This commit is contained in:
parent
e7338c341f
commit
4ae5e83fb9
2 changed files with 0 additions and 0 deletions
16
ipv4_linux_test.go
Normal file
16
ipv4_linux_test.go
Normal file
|
@ -0,0 +1,16 @@
|
|||
package water
|
||||
|
||||
import (
|
||||
"net"
|
||||
"os/exec"
|
||||
"testing"
|
||||
)
|
||||
|
||||
func setupIfce(t *testing.T, ipNet net.IPNet, dev string) {
|
||||
if err := exec.Command("ip", "link", "set", dev, "up").Run(); err != nil {
|
||||
t.Fatal(err)
|
||||
}
|
||||
if err := exec.Command("ip", "addr", "add", ipNet.String(), "dev", dev).Run(); err != nil {
|
||||
t.Fatal(err)
|
||||
}
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue