Description
This test case ensures that Fedora can successfully use Toolbox for managing containers, specifically by listing, creating, and running Toolbox containers. Optionally, this test case can also be used to test a specific Toolbox container image, for instance the one produced by a Fedora compose undergoing validation testing.
Setup
Download and install the latest version of Fedora on a bare metal system or virtual machine. Ensure that toolbox
is installed on the system.
How to test
- Open a terminal on the Fedora system.
- Optionally, to test a specific Toolbox container image - e.g. when doing release validation testing:
- Download the image (for release validation testing, you can find the URL for the Toolbox image from the Container_Toolbox docker row of the image table at the top of the validation matrix page).
- Import the image by running
skopeo copy docker-archive:/path/to/imagefile containers-storage:registry.fedoraproject.org/fedora-toolbox:42
. Replace /path/to/imagefile with the actual path to the downloaded image, and adjust the release number as appropriate.
- Execute the command
toolbox list
to display the list of available Toolbox containers. Note the initial number of containers. - Execute the command
toolbox create
to create a new Toolbox container using the default settings.- If you are testing a specific toolbox container image, and the release number you used when importing it is not the same as the release number for the host distribution, run
toolbox create --release 42
, or whatever the appropriate number is. If you do this correctly, toolbox should not prompt you to download an image.
- If you are testing a specific toolbox container image, and the release number you used when importing it is not the same as the release number for the host distribution, run
- Execute the command
toolbox list
again to verify that the new container has been created and is listed. - Execute the command
toolbox enter
to enter the newly created Toolbox container.- If you are testing a specific toolbox container image, and the release number you used when importing it is not the same as the release number for the host system, run
toolbox enter --release 42
, or whatever the appropriate number is.
- If you are testing a specific toolbox container image, and the release number you used when importing it is not the same as the release number for the host system, run
- Inside the Toolbox container, execute the command
echo "Hello from Toolbox"
to verify that commands can be run within the container. - Exit the Toolbox container by executing the command exit.
Expected Results
- The toolbox list command displays the list of available Toolbox containers without errors.
- The toolbox create command successfully creates a new Toolbox container.
- The new container is listed in the output of the toolbox list command after creation.
- The toolbox enter command successfully enters the newly created Toolbox container.
- Commands can be executed within the Toolbox container, as shown by the output of the echo command.
- The exit command successfully exits the Toolbox container.
Optional
Optionally, test different Toolbox configurations, such as creating containers with custom names, creating containers based on different images, and running various commands within the containers to ensure that Fedora can handle a wide range of Toolbox scenarios.