fedora-qa / openqa_testdata

Created 2 years ago
Maintained by lruzicka
This repository contains files to be downloaded into the tested VM to have some content to test on.
Members 1
Lukáš Růžička committed 13 days ago

OpenQA-TestData repository

This repository contains test files that our openQA tests use for Desktop testing.

Structure

Directories

Notice the repository directory structure. There are several directories, such as:

  • configuration
  • documents
  • music
  • pictures
  • reference
  • video

Each of those directories contains the data related to its name, i.e. documents are placed in documents, video files in video, etc.

The reference directory

This directory is for reference files that might include command outputs from a working system, that you can use to compare with the same output from a tested machine. Do not place anything else in this directory.

The configuration directory

This directory contains configuration files for various applications that we do not want to create during the tests.

Tar.gz file

The repository.tar.gz file is an archive file that includes all the above directories and their content. This file will be downloaded by the openQA tests and used to populate the tested system's directory structure, e.g. the content of the documents folder will be copied into the Documents folder of the tested machine, etc.

Content

When adding content, make sure that you respect the structure and that you recreate the archive to include the changes. You also need to keep the name of the archive, otherwise, the target VM will not be able to receive them.

To recreate the archive, do not include the git repository files, use tar --exclude='.git' -czvf repository.tar.gz ./.

For space demanding content, such as multimedia files or pdfs, make sure they are as much compressed as possible to keep the overall amount of transferred data low.

Using this repository in openQA tests

To use this repository in a test, use the download_testdata subroutine located in the lib/utils.pm file.

The following example shows how you can use it in a test script:

use utils;

sub {
    download_testdata;
}