Conversation
This new chapter summarizes features for efficient metadata handling, covering: - fmf inheritance - adjust based on context - YAML referencing features (anchors and aliases) - sharing tests across repositories The chapter is added in `docs/guide/efficient-metadata.inc.rst` and included in `docs/guide.rst`.
This new section in `docs/guide.rst` summarizes features for efficient metadata handling, covering: - fmf inheritance - adjust based on context - YAML referencing features (anchors and aliases) - sharing tests across repositories This addresses your feedback to add the content directly into the main guide file instead of a separate .inc.rst file.
mcasquer
pushed a commit
that referenced
this pull request
Aug 19, 2025
In verbose mode `-v` print the duration limit for each test during the
execute step.
Add tests to verify the correct value is printed.
For reference, how the log output looks on a failing test due to timeout
(updated after shift commit):
`-v`
```
execute
queued execute task #1: default-0 on default-0
execute task #1: default-0 on default-0
how: tmt
duration limit: 2 seconds
00:00:02 errr /test/duration-modified (on default-0) [1/1]
00:00:00 fail internal/timeout (after-test check)
Note: Test exceeded maximum duration of 2s
summary: 1 test executed
```
`-vv`
```
execute
queued execute task #1: default-0 on default-0
execute task #1: default-0 on default-0
how: tmt
ignore-duration: false
exit-first: false
test: Adjust the duration in test metadata
duration limit: 2 seconds
cmd: sleep 3s
00:00:02 errr /test/duration-modified (on default-0) [1/1]
00:00:00 fail internal/timeout (after-test check)
Note: Test exceeded maximum duration of 2s
summary: 1 test executed
```
TF runs tmt with `-v`
Fixes [teemtee#3856](teemtee#3856).
mcasquer
pushed a commit
that referenced
this pull request
Jan 19, 2026
Previously, SUPPORTED_DISTRO_PATTERNS was a
(shared) generator. That breaks use of fips prepare feature in multiple
plans within the same tmt run. Now SUPPORTED_DISTRO_PATTERS is just a
tuple and sharing has no negative effects.
Consider the following plan:
```
# reproducer.fmf
summary: Test plan
prepare:
- name: Enable FIPS mode
how: feature
fips: enabled
execute:
how: tmt
discover:
- how: shell
tests:
- name: sample-test
test: echo 'hello!'
/first:
/second:
```
Previously:
```
❯ tmt run plan --name /plans/reproducer discover provision --how minute --image rhel-10.1 prepare
/var/tmp/tmt/run-001
/plans/reproducer/first
discover
...
provision
....
summary: 1 guest provisioned
prepare
queued push task #1: push to default-0
push task #1: push to default-0
queued prepare task #1: essential-requires on default-0
queued prepare task #2: Enable FIPS mode on default-0
prepare task #1: essential-requires on default-0
how: install
summary: Install essential required packages
name: essential-requires
where: default-0
package: /usr/bin/python3 and /usr/bin/flock
prepare task #2: Enable FIPS mode on default-0
how: feature
name: Enable FIPS mode
Enable FIPS
queued pull task #1: pull from default-0
pull task #1: pull from default-0
summary: 2 preparations applied
/plans/reproducer/second
discover
...
provision
...
summary: 1 guest provisioned
prepare
queued push task #1: push to default-0
push task #1: push to default-0
queued prepare task #1: essential-requires on default-0
queued prepare task #2: Enable FIPS mode on default-0
prepare task #1: essential-requires on default-0
how: install
summary: Install essential required packages
name: essential-requires
where: default-0
package: /usr/bin/python3 and /usr/bin/flock
prepare task #2: Enable FIPS mode on default-0
how: feature
name: Enable FIPS mode
fail: FIPS prepare feature is supported on RHEL/CentOS-Stream 8, 9 or 10.
plan failed
The exception was caused by 1 earlier exceptions
Cause number 1:
prepare step failed
The exception was caused by 1 earlier exceptions
Cause number 1:
FIPS prepare feature is supported on RHEL/CentOS-Stream 8, 9 or 10.
```
This is because now `SUPPORTED_DISTRO_PATTERNS` is a generator now.
```
SUPPORTED_DISTRO_PATTERNS = (
re.compile(pattern)
for pattern in (r'Red Hat Enterprise Linux (8|9|10)', r'CentOS Stream (8|9|10)')
)
```
And the prepare phase of the first plan already takes the first pattern
and hence there is nothing useful left for the prepare phase of the
second plan.
Signed-off-by: Ondrej Moris <ondrej.moris@gmail.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This is a Jules test