diff options
author | Andrei Vagin <avagin@gmail.com> | 2020-09-14 15:32:46 -0700 |
---|---|---|
committer | Andrei Vagin <avagin@gmail.com> | 2020-09-16 12:22:17 -0700 |
commit | f148242abab1ff043428036ccaf464de98268863 (patch) | |
tree | 1e57aea21f2fe0cfaf7031d6fa4b9f2fb3b0aa8c /test/image/image_test.go | |
parent | 113928754c26ea3d4d7d387bae459ce447774d30 (diff) |
Revert "fuse: add benchmarking support for FUSE"
test/fuse/benchmark/read_benchmark.cc:34: Failure
Expected: (fuse_prefix) != (nullptr), actual: NULL vs (nullptr)
external/com_google_benchmark/src/benchmark_runner.cc:120: RunInThread:
Check `st.iterations() >= st.max_iterations' failed. Benchmark returned
before State::KeepRunning() returned false!
--- FAIL: Benchmarks_BM_Read/262144/real_time (0.29s)
runner.go:502: test "Benchmarks.BM_Read/262144/real_time" failed
with error exit status 134, want nil
FAIL
Diffstat (limited to 'test/image/image_test.go')
-rw-r--r-- | test/image/image_test.go | 52 |
1 files changed, 0 insertions, 52 deletions
diff --git a/test/image/image_test.go b/test/image/image_test.go index 6b5928ef0..ac6186688 100644 --- a/test/image/image_test.go +++ b/test/image/image_test.go @@ -33,7 +33,6 @@ import ( "testing" "time" - "github.com/docker/docker/api/types/mount" "gvisor.dev/gvisor/pkg/test/dockerutil" "gvisor.dev/gvisor/pkg/test/testutil" ) @@ -64,57 +63,6 @@ func TestHelloWorld(t *testing.T) { } } -// Test that the FUSE container is set up and being used properly. -func TestFUSEInContainer(t *testing.T) { - if usingFUSE, err := dockerutil.UsingFUSE(); err != nil { - t.Fatalf("failed to read config for runtime %s: %v", dockerutil.Runtime(), err) - } else if !usingFUSE { - t.Skip("FUSE not being used.") - } - - ctx := context.Background() - d := dockerutil.MakeContainer(ctx, t) - defer d.CleanUp(ctx) - - tmpDir := "/tmpDir/" - // Run the basic container. - err := d.Spawn(ctx, dockerutil.RunOpts{ - Image: "basic/fuse", - Privileged: true, - CapAdd: []string{"CAP_SYS_ADMIN"}, - - // Mount a tmpfs directory for benchmark. - Mounts: []mount.Mount{ - { - Type: mount.TypeTmpfs, - Target: tmpDir, - ReadOnly: false, - }, - }, - }, "sleep", "1000") - if err != nil { - t.Fatalf("docker spawn failed: %v", err) - } - - out, err := d.Exec(ctx, dockerutil.ExecOpts{ - Privileged: true, - }, "/bin/sh", "-c", "ls") - if err != nil { - t.Fatalf("docker exec failed: %v, message %s", err, out) - } - if !strings.Contains(out, "server-bin") { - t.Fatalf("docker didn't find server binary: got %s", out) - } - - // Run the server. - out, err = d.Exec(ctx, dockerutil.ExecOpts{ - Privileged: true, - }, "/bin/sh", "-c", "./server-bin mountpoint") - if err != nil { - t.Fatalf("docker exec failed: %v, message %s", err, out) - } -} - func runHTTPRequest(port int) error { url := fmt.Sprintf("http://localhost:%d/not-found", port) resp, err := http.Get(url) |