summaryrefslogtreecommitdiffhomepage
path: root/runsc/container
diff options
context:
space:
mode:
authorZach Koopmans <zkoopmans@google.com>2020-04-17 10:38:04 -0700
committergVisor bot <gvisor-bot@google.com>2020-04-17 10:39:19 -0700
commit12bde95635ac266aab8087b4705372bb177638f3 (patch)
tree8fd9a3f9740cfb632c04d7da6ffdce161f5cdb9e /runsc/container
parent4a818d64378f16f3738ba51c7804cff90f753b1d (diff)
Get /bin/true to run on VFS2
Included: - loader_test.go RunTest and TestStartSignal VFS2 - container_test.go TestAppExitStatus on VFS2 - experimental flag added to runsc to turn on VFS2 Note: shared mounts are not yet supported. PiperOrigin-RevId: 307070753
Diffstat (limited to 'runsc/container')
-rw-r--r--runsc/container/container_test.go14
1 files changed, 13 insertions, 1 deletions
diff --git a/runsc/container/container_test.go b/runsc/container/container_test.go
index 442e80ac0..24f9ecc35 100644
--- a/runsc/container/container_test.go
+++ b/runsc/container/container_test.go
@@ -521,9 +521,21 @@ func TestExePath(t *testing.T) {
// Test the we can retrieve the application exit status from the container.
func TestAppExitStatus(t *testing.T) {
+ conf := testutil.TestConfig()
+ conf.VFS2 = false
+ doAppExitStatus(t, conf)
+}
+
+// This is TestAppExitStatus for VFSv2.
+func TestAppExitStatusVFS2(t *testing.T) {
+ conf := testutil.TestConfig()
+ conf.VFS2 = true
+ doAppExitStatus(t, conf)
+}
+
+func doAppExitStatus(t *testing.T, conf *boot.Config) {
// First container will succeed.
succSpec := testutil.NewSpecWithArgs("true")
- conf := testutil.TestConfig()
rootDir, bundleDir, err := testutil.SetupContainer(succSpec, conf)
if err != nil {
t.Fatalf("error setting up container: %v", err)