Skip to content

Add initial tmt test plan#974

Draft
archanaserver wants to merge 6 commits intotheforeman:masterfrom
archanaserver:tmt-init
Draft

Add initial tmt test plan#974
archanaserver wants to merge 6 commits intotheforeman:masterfrom
archanaserver:tmt-init

Conversation

@archanaserver
Copy link

No description provided.

Copy link
Contributor

@adamruzicka adamruzicka left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Could we put all those files being added here into a single directory rather than having them scattered over the repo root, .fmf, plans and tests or is the current structure dictated by tmt?

- job: tests
trigger: pull_request
targets:
- epel-9
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can this be rhel-9? Alternatively we'll probably need to set up additional repos here

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can you be more descriptive please I might not get it?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The previous build failed with this - apparently it tried to build the rpm without having access to the other repositories we supply for the copr_build job.

No matching package to install: 'foreman-assets >= 3.15'
No matching package to install: 'foreman-plugin >= 3.15'
No matching package to install: 'npm(@theforeman/builder) >= 15.0.1'
No matching package to install: 'rubygem(deface)'
No matching package to install: 'rubygem(foreman-tasks) >= 8.3.0'

With the rhel-9 thing, I was hoping that if we used the same target for both of those jobs, things would sort themselves out, but apparently that is not an available target on testing farm, so I'm sorry for that. So back to epel-9 and we'll see where it takes us

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Now we're back where we were, would something like this change anything?

Suggested change
- epel-9
epel-9:
additional_modules: "foreman-devel:el9"
additional_repos:
- https://yum.theforeman.org/releases/nightly/el9/x86_64/
- https://yum.theforeman.org/plugins/nightly/el9/x86_64/

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

i guess this is what i saw missing, trying it for now...

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

968e68d this seems to be the way forward. It will at least allow the test job to be triggered in testing farm

@archanaserver
Copy link
Author

Could we put all those files being added here into a single directory rather than having them scattered over the repo root, .fmf, plans and tests or is the current structure dictated by tmt?

Thanks for the review @adamruzicka and for pointing this out!
I initially followed the scattered layout based on some earlier references and examples. That said, I’ve tried to re-structure it this way to clearly separate host-side orchestration (via hammer) from guest-side testing, which helps avoid some common pitfalls I believe when integrating TMT with Foreman.

@packit-as-a-service
Copy link

Failed to load packit config file:

Cannot parse package config. ValidationError({'jobs': {1: {'packages': defaultdict(<class 'dict'>, {'rubygem-foreman_remote_execution': {'value': {'targets': ["Expected 'list[str]' or 'dict[str,dict]', got [{'epel-9': None}] (type <class 'list'>)."]}}})}}})

For more info, please check out the documentation or contact the Packit team. You can also use our CLI command config validate or our pre-commit hooks for validation of the configuration.

@archanaserver
Copy link
Author

@adamruzicka i see some failures, could you help me understand if these are expected issues because of this changes?

@adamruzicka
Copy link
Contributor

The failures in unit tests through github actions are unrelated to the changes proposed here.

The testing-farm failure however, is related. If I'm reading it right, then packit builds a package, then testing farm spins up a standard centos9stream machine and tries to install the packit-built rpm there, but since this is a foreman plugin, the rpm cannot be installed on its own.

provision:
how: virtual
image: centos-stream-9

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

prepare:
    how: install
    package:
      - https://yum.theforeman.org/releases/nightly/el9/x86_64/foreman-release.rpm

should setup enough repos to make things install fine

@archanaserver
Copy link
Author

The plan on this is unclear right now, so moving it to draft for now.

@archanaserver archanaserver marked this pull request as draft November 6, 2025 09:05
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants