Tag: testing (page 1 of 9)

Improve traceability with the tmt web app

The tmt web app is a simple web application that makes it easy to explore and share test and plan metadata without needing to clone repositories or run tmt commands locally.

At the beginning, there was the following user story:

As a tester, I need to be able to link the test case(s) verifying the issue so that anyone can easily find the tests for the verification.

Traceability is an important aspect of the testing process. It is essential to have a bi-directional link between test coverage and issues covered by those tests so that we can easily:

  • identify issues covered by the given test
  • locate tests covering given issues

Link issue from test

Implementing the first direction in tmt was relatively easy: We just defined a standard way to store links with their relations. This is covered by the core link key which holds a list of relation:link pairs. Here’s an example test metadata:

summary: Verify correct escaping of special characters
test: ./test.sh
link:
  - verifies: https://issues.redhat.com/browse/TT-206

Link test from issue

The solution for the second direction was not that straightforward. Thanks to its distributed nature, tmt does not have any central place where a Jira issue could point to. There is no server which keeps information about all tests and stores a unique id number for each which could be used in the link.

Instead of integers, we’re using the fmf id as the unique identifier. It contains url of the git repository and name of the test. Optionally, it can also define ref instead of using the default branch and path to the fmf tree if it’s not in the git root.

The tmt web app accepts an fmf id of the test or plan or both, clones the git repository, extracts the metadata, and returns the data in your preferred format:

  • HTML for human-readable viewing
  • JSON or YAML for programmatic access

The service is currently available at the following location:

Here’s an example of what the parameters would look like when requesting information about a test in the default branch of a git repository:

By default, a human-readable HTML version of the output is provided to the user. Include the format parameter in order to choose your preferred format:

It is possible to link a test, a plan, or both test and plan. The last option can be useful when a single test is executed under several plans. Here’s how the human readable version looks like:

Create new tests

In order to make the linking as smooth as possible, the tmt test create command was extended to allow automated linking to Jira issues.

First make sure you have the .config/tmt/link.fmf config prepared. Check the Link Issues section for more details about the configuration.

issue-tracker:
  - type: jira
    url: https://issues.redhat.com
    tmt-web-url: https://tmt.testing-farm.io/
    token: ***

When creating a new test, use the --link option to provide the issue which is covered by the test:

tmt test create /tests/area/feature --template shell --link verifies:https://issues.redhat.com/browse/TT-206

The link will be added to both test metadata and the Jira issue. Just note that the Jira link will be working once you push the changes to the remote repository.

Link existing objects

It’s also possible to use the tmt link command to link issue with already existing tests or plans:

tmt link --link verifies:https://issues.redhat.com/browse/TT-206 /tests/core/escaping

If both test and plan should be linked to the issue, provide both test and plan as the names:

tmt link --link verifies:https://issues.redhat.com/browse/TT-206 /tests/core/escaping /plans/features/core

This is how the created links would look like in Jira:

Closing notes

As a proof of concept, for now there is only a single public instance of the tmt web app deployed, so be aware that it can only explore git repositories that are publicly available. For the future we consider creating an internal instance in order to be able to access internal repositories as well.

We are looking for early feedback. If you run into any problems or any missing features, please let us know by filing a new issue. Thanks!

Call for Fedora Linux 39 Test Days

It’s time to start thinking about Test Days for Fedora Linux 39. A Test Day is an event aimed getting interested users and developers together to test a specific feature or area of the distribution. You can run a Test Day on just about anything for which it would be useful to do some fairly focused testing in ‘real time’ with a group of testers; it doesn’t have to be code. For instance, we often run Test Days for localization and internationalization topics.

Continue reading

Call for Fedora Linux 38 Test Days

It’s time to start thinking about Test Days for Fedora Linux 38. A Test Day is an event aimed getting interested users and developers together to test a specific feature or area of the distribution. You can run a Test Day on just about anything for which it would be useful to do some fairly focused testing in ‘real time’ with a group of testers; it doesn’t have to be code. For instance, we often run Test Days for localization and internationalization topics.

Continue reading

Contribute to Fedora 37 Upgrade Test Day

Fedora test days are events where anyone can help make sure changes in Fedora Linux work well in an upcoming release. Fedora community members often participate, and the public is welcome at these events. If you’ve never contributed to Fedora before, this is a perfect way to get started. The F37 Upgrade Test Day is Wednesday, October 5.

Continue reading

Contribute at the Fedora Linux 37 Test Week for Kernel 5.18

The kernel team is working on final integration for Linux kernel 5.18. This version was just recently released, and will arrive soon in Fedora. As a result, the Fedora kernel and QA teams have organized a test week now through Sunday, June 05, 2022. Refer to the wiki page for links to the test images you’ll need to participate. Read below for details.

Continue reading

Call for F37 Test Days

It’s time to start thinking about Test Days for Fedora Linux 37. A Test Day is an event aimed getting together interested users and developers to test a specific feature or area of the distribution. You can run a Test Day on just about anything for which it would be useful to do some fairly focused testing in ‘real time’ with a group of testers; it doesn’t have to be code. For instance, we often run Test Days for l10n/i18n topics. For more information on Test Days, see the wiki.

Continue reading

Contribute at the Fedora 36 CoreOS Test Week

The Fedora CoreOS team released the first Fedora CoreOS next stream release based on Fedora Linux 36. They expect to promote this to the testing stream in two weeks, on the usual schedule. As a result, the Fedora CoreOS and QA teams have organized a test week. It is underway now and runs through the end of the week. Refer to the wiki page for links to the test cases and materials you’ll need to participate. Read below for details.

Continue reading

Contribute at the Fedora Linux 36 Test Week for Kernel 5.17

The kernel team is working on final integration for Linux kernel 5.17. This version was just recently released, and will arrive soon in Fedora. As a result, the Fedora kernel and QA teams have organized a test week now through Sunday, April 10, 2022. Refer to the wiki page for links to the test images you’ll need to participate. Read below for details.

Continue reading

Help Us Test Fedora Linux 36 Beta wallpaper

The final F36 day and night beta wallpapers are here! Take a look below and let us know what your thoughts are!

Continue reading

Contribute at the Fedora Linux 36 Test Week for Kernel 5.16

The kernel team is working on final integration for kernel 5.16. This version was just recently released, and will arrive soon in Fedora. As a result, the Fedora kernel and QA teams have organized a test week from Sunday, January 23, 2022 through Sunday, January 29, 2022. Refer to the wiki page for links to the test images you’ll need to participate. Read below for details.

Continue reading
Olderposts

Copyright © 2026 Fedora Community Blog

Creative Commons License
This work is licensed under a Creative Commons Attribution 4.0 International License.

Theme by Anders NorenUp ↑