Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

e2e: Initial e2e code #34

Merged
merged 1 commit into from
May 11, 2023
Merged

e2e: Initial e2e code #34

merged 1 commit into from
May 11, 2023

Conversation

dougsland
Copy link
Collaborator

$ ./run-test-e2e
[ INFO ] Starting setup
[ INFO ] ==============================
[ INFO ] Cleaning any previous e2e files
[ INFO ] Creating podman network [netcow]

[ INFO ] Preparing ASIL environment
[ INFO ] ==============================
[ INFO ] Creating container control [ASIL mode]
[ INFO ] Creating stub systemd service: container-safety in container control
[ INFO ] Creating stub systemd service: container-cruise_control in container control
[ INFO ] Creating stub systemd service: container-tires in container control
[ INFO ] Creating stub systemd service: container-breaks in container control

[ INFO ] Preparing QM environment
[ INFO ] ==============================
[ INFO ] Creating container node1 [QM mode]
[ INFO ] Creating containers radio, maps, store
[ INFO ] See: https://github.com/containers/qm/issues/32

[ INFO ] Starting tests
[ INFO ] ==============================
[ INFO ] Waiting hirte containers be ready...

[ INFO ] #1- Test scenario: hirte list all units from control to node (vise-versa)
[ INFO ] Connected to control, listing few systemd units from control
[ INFO ] Executing: podman exec control hirtectl list-units control | head -5
ID                                                                              |   ACTIVE|      SUB
====================================================================================================
dbus.socket                                                                     |   active|  running
dev-cpu-19-msr.mount                                                            |   active|  mounted
integritysetup.target                                                           |   active|   active

[ INFO ] Connected to control, listing few systemd units from node1
[ INFO ] Executing: podman exec control hirtectl list-units node1 | head -5
ID                                                                              |   ACTIVE|      SUB
====================================================================================================
sys-fs-fuse-connections.mount                                                   | inactive|     dead
systemd-machine-id-commit.service                                               | inactive|     dead
dev-cpu-4-cpuid.mount                                                           |   active|  mounted

[ INFO ] All set!

@dougsland
Copy link
Collaborator Author

dougsland commented May 7, 2023

before merge:

future:

  • open an issue to support fedora (other distros?) in e2e, today uses centos9
  • share the e2e with hirte project? (we use hirte a bunch here)

/cc @rhatdan for review

@dougsland
Copy link
Collaborator Author

/hold

@lsm5
Copy link
Member

lsm5 commented May 9, 2023

Not a review, just a note: it would be great to integrate these tests with Packit and TMT (https://packit.dev/docs/testing-farm/) . Doesn't have to be in this PR, and fwiw, we don't have e2e testing with packit complete in any of our repos yet.

@dougsland
Copy link
Collaborator Author

Not a review, just a note: it would be great to integrate these tests with Packit and TMT (https://packit.dev/docs/testing
-farm/) . Doesn't have to be in this PR, and fwiw, we don't have e2e testing with packit complete in any of our repos yet.

Thanks @lsm5. Indeed, it will require a different github issue (as soon we merge) as I will need to research the tool to start using it.

@rhatdan
Copy link
Member

rhatdan commented May 10, 2023

@dougsland Still a WIP?

@lsm5
Copy link
Member

lsm5 commented May 10, 2023

Not a review, just a note: it would be great to integrate these tests with Packit and TMT (https://packit.dev/docs/testing
-farm/) . Doesn't have to be in this PR, and fwiw, we don't have e2e testing with packit complete in any of our repos yet.

Thanks @lsm5. Indeed, it will require a different github issue (as soon we merge) as I will need to research the tool to start using it.

containers/container-selinux#230 might be of some use. It's not merged yet and actually running those tests does cause out of disk space issues on the testing env, that I have yet to check on. TMT does allow specifying hardware configuration, but I haven't yet gotten it to work successfully: https://tmt.readthedocs.io/en/stable/spec/hardware.html#disk

@dougsland
Copy link
Collaborator Author

dougsland commented May 11, 2023

@dougsland Still a WIP?

@rhatdan almost there, we need a README and a fresh test "tomorrow". As today I got surprised with some changes in the new rpm.

@dougsland dougsland changed the title [WIP] e2e: Initial e2e code e2e: Initial e2e code May 11, 2023
@dougsland
Copy link
Collaborator Author

read for the review @rhatdan @lsm5

Copy link
Member

@lsm5 lsm5 left a comment

Choose a reason for hiding this comment

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

Could you please also add in the commit message how to actually run the test (which dir to run from), as root / non-root etc?

@lsm5
Copy link
Member

lsm5 commented May 11, 2023

Could you please also add in the commit message how to actually run the test (which dir to run from), as root / non-root etc?

and also in the README

tests/e2e/README.md Outdated Show resolved Hide resolved
tests/e2e/README.md Outdated Show resolved Hide resolved
tests/e2e/README.md Outdated Show resolved Hide resolved
@rhatdan
Copy link
Member

rhatdan commented May 11, 2023

Cleanup @lsm5 issues, and then we can merge. We need to get this test to run on PRs.

@lsm5
Copy link
Member

lsm5 commented May 11, 2023

I think if we need something running quickly, github actions might be the way, although I don't think it's easy to provision anything other than Ubuntu over there. Packit + TMT might be the way to go long-term.

@dougsland
Copy link
Collaborator Author

Could you please also add in the commit message how to actually run the test (which dir to run from), as root / non-root
etc?

Just run ./run-e2e-test in the dir. There is a asciicinema embedded in the README that show as 'video' how to run it.

@dougsland
Copy link
Collaborator Author

Could you please also add in the commit message how to actually run the test (which dir to run from), as root / non-root etc?

The script will warn if user try to run as non root.

GH-Issue: #33
Signed-off-by: Douglas Schilling Landgraf <[email protected]>
@dougsland
Copy link
Collaborator Author

@rhatdan @lsm5 here how the HTML will look like when README.md is merged: https://github.com/dougsland/qm/tree/e2e/tests/e2e

Copy link
Member

@lsm5 lsm5 left a comment

Choose a reason for hiding this comment

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

LGTM

@lsm5 lsm5 merged commit 76d8642 into containers:main May 11, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants