From Fedora Project Wiki

(Created page with "{{QA/Test_Case |description=This test aims to verify that the exit status from sandboxed commands is correctly propagated to the host |actions= # Run a command with "normal" exit...")
 
No edit summary
Line 21: Line 21:
#: # echo $?
#: # echo $?
|results=
|results=
# Step#1: 0
# 0
# Step#1: 0
# 0
# Step#1: 1
# 1
# Step#1: 1
# 1
# Step#1: 4
# 4
# Step#1: 4
# 4
}}
}}


[[Category:Virtualization_VirtSandbox_Test_Cases]]
[[Category:Virtualization_VirtSandbox_Test_Cases]]

Revision as of 12:40, 13 April 2012

Description

This test aims to verify that the exit status from sandboxed commands is correctly propagated to the host


How to test

  1. Run a command with "normal" exit status
    # /bin/true
    # echo $?
  2. Run a command with "normal" exit status in a sandbox
    # virt-sandbox -c $URI /bin/true
    # echo $?
  3. Run a command with "error" exit status
    # /bin/false
    #echo $?
  4. Run a command with "error" exit status in a sandbox
    # virt-sandbox -c $URI /bin/false
    # echo $?
  5. Run a command with a custom exit status
    # /bin/sh "exit 4"
    # echo $?
  6. Run a command with a custom exit status in a sandbox
    # virt-sandbox -c $URI -- /bin/sh -c "exit 4"
    # echo $?

Expected Results

  1. 0
  2. 0
  3. 1
  4. 1
  5. 4
  6. 4