diff options
| author | Dmitry Vyukov <dvyukov@google.com> | 2018-04-06 18:46:49 +0200 |
|---|---|---|
| committer | Dmitry Vyukov <dvyukov@google.com> | 2018-04-06 18:47:56 +0200 |
| commit | 4daf8570eba286299489fc3ebc7d788c458bb47a (patch) | |
| tree | 99b413a3fad8b7f7bf87c6a1fe957aa0a6112d75 /pkg/host/host_linux_test.go | |
| parent | 48a846e42b1ef210d410b783656c59d5c2827e11 (diff) | |
pkg/host: explain why syscalls are disabled
Diffstat (limited to 'pkg/host/host_linux_test.go')
| -rw-r--r-- | pkg/host/host_linux_test.go | 37 |
1 files changed, 1 insertions, 36 deletions
diff --git a/pkg/host/host_linux_test.go b/pkg/host/host_linux_test.go index 9deda69bc..084428ab2 100644 --- a/pkg/host/host_linux_test.go +++ b/pkg/host/host_linux_test.go @@ -11,50 +11,15 @@ import ( "testing" "github.com/google/syzkaller/prog" - _ "github.com/google/syzkaller/sys" ) -func TestLog(t *testing.T) { - t.Parallel() - target, err := prog.GetTarget("linux", runtime.GOARCH) - if err != nil { - t.Fatal(err) - } - // Dump for manual inspection. - supp, err := DetectSupportedSyscalls(target, "none") - if err != nil { - t.Skipf("skipping: %v", err) - } - t.Logf("unsupported:") - for _, c := range target.Syscalls { - s, ok := supp[c] - if ok && !s { - t.Fatalf("map contains false value") - } - if !s { - t.Logf("\t%v", c.Name) - } - } - trans := target.TransitivelyEnabledCalls(supp) - t.Logf("transitively unsupported:") - for _, c := range target.Syscalls { - s, ok := trans[c] - if ok && !s { - t.Fatalf("map contains false value") - } - if !s && supp[c] { - t.Logf("\t%v", c.Name) - } - } -} - func TestSupportedSyscalls(t *testing.T) { t.Parallel() target, err := prog.GetTarget("linux", runtime.GOARCH) if err != nil { t.Fatal(err) } - supp, err := DetectSupportedSyscalls(target, "none") + supp, _, err := DetectSupportedSyscalls(target, "none") if err != nil { t.Skipf("skipping: %v", err) } |
