Skip to content

test(e2e): add TPM test case#1480

Draft
hayer969 wants to merge 5 commits intomainfrom
test/e2e/check-tpm
Draft

test(e2e): add TPM test case#1480
hayer969 wants to merge 5 commits intomainfrom
test/e2e/check-tpm

Conversation

@hayer969
Copy link
Contributor

@hayer969 hayer969 commented Sep 21, 2025

Description

This PR updates e2e tests to check that VM properly recognizes tpm device.

Checklist

  • The code is covered by unit tests.
  • e2e tests passed.
  • Documentation updated according to the changes.
  • Changes were tested in the Kubernetes cluster manually.

@hayer969 hayer969 added this to the v1.1.0 milestone Sep 21, 2025
@hayer969 hayer969 added the e2e/run Run e2e test on cluster of PR author label Sep 21, 2025
@deckhouse-BOaTswain
Copy link
Contributor

deckhouse-BOaTswain commented Sep 21, 2025

Workflow has started.
Follow the progress here: Workflow Run

The target step completed with status: failure.

@deckhouse-BOaTswain deckhouse-BOaTswain removed the e2e/run Run e2e test on cluster of PR author label Sep 21, 2025
@hayer969 hayer969 added e2e/user/hayer969 e2e/run Run e2e test on cluster of PR author labels Sep 21, 2025
@nevermarine nevermarine added e2e/run Run e2e test on cluster of PR author and removed e2e/run Run e2e test on cluster of PR author e2e/user/hayer969 labels Sep 22, 2025
@deckhouse-BOaTswain
Copy link
Contributor

deckhouse-BOaTswain commented Sep 22, 2025

Workflow has started.
Follow the progress here: Workflow Run

The target step completed with status: failure.

@deckhouse-BOaTswain deckhouse-BOaTswain removed the e2e/run Run e2e test on cluster of PR author label Sep 22, 2025
@nevermarine nevermarine added the e2e/run Run e2e test on cluster of PR author label Sep 22, 2025
@deckhouse-BOaTswain
Copy link
Contributor

deckhouse-BOaTswain commented Sep 22, 2025

Workflow has started.
Follow the progress here: Workflow Run

The target step completed with status: cancelled.

@hayer969 hayer969 marked this pull request as ready for review September 22, 2025 09:54
@deckhouse-BOaTswain deckhouse-BOaTswain removed the e2e/run Run e2e test on cluster of PR author label Sep 22, 2025
@hayer969 hayer969 marked this pull request as draft September 24, 2025 09:30
@nevermarine nevermarine modified the milestones: v1.1.0, v1.2.0 Oct 6, 2025
@Isteb4k Isteb4k modified the milestones: v1.2.0, v1.1.1 Oct 14, 2025
@nevermarine nevermarine modified the milestones: v1.1.1, v1.2.0 Oct 16, 2025
@Isteb4k Isteb4k modified the milestones: v1.2.0, v1.3.0 Nov 26, 2025
@hayer969 hayer969 requested a review from Isteb4k as a code owner December 15, 2025 11:53
@nevermarine nevermarine modified the milestones: v1.3.0, v1.4.0 Dec 16, 2025
@hayer969 hayer969 marked this pull request as draft December 16, 2025 14:19
@hayer969 hayer969 force-pushed the test/e2e/check-tpm branch 4 times, most recently from d513d5a to fd9de56 Compare December 25, 2025 13:59
@hayer969 hayer969 marked this pull request as ready for review December 25, 2025 14:01
@hayer969 hayer969 added the e2e/run Run e2e test on cluster of PR author label Dec 25, 2025
@deckhouse-BOaTswain
Copy link
Contributor

deckhouse-BOaTswain commented Dec 25, 2025

Workflow has started.
Follow the progress here: Workflow Run

The target step completed with status: failure.

@deckhouse-BOaTswain deckhouse-BOaTswain removed the e2e/run Run e2e test on cluster of PR author label Dec 25, 2025
vd.WithSize(ptr.To(resource.MustParse(vdsize))),
vd.WithNamespace(f.Namespace().Name),
vd.WithDataSourceHTTP(&v1alpha2.DataSourceHTTP{
URL: imageURLDebian12,
Copy link
Contributor

Choose a reason for hiding this comment

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

But osType is "Windows".

Copy link
Contributor Author

Choose a reason for hiding this comment

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

It is question for naming this feature, not for used OS. Debian more handy in auto test than Windows, and it is excellent fit purpose of this test.

Expect(err).NotTo(HaveOccurred())

By("Waits QEMU agent to be ready")
util.UntilVMAgentReady(client.ObjectKeyFromObject(vmTPM), framework.LongTimeout)
Copy link
Contributor

Choose a reason for hiding this comment

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

Is it necessary in this test case?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

In this test I install additional packages in the OS And check result through ssh. I didn't check whether it always works immediately after the virtual machine entered the Running phase, or it could lead to flaky tests.

@hardcoretime hardcoretime changed the title test(e2e): check that the tpm module is recognized in the os test(e2e): add TPM test case Dec 28, 2025
Dmitry Prytkov and others added 4 commits December 29, 2025 13:16
Create legacy test for check tpm

Signed-off-by: Dmitry Prytkov <[email protected]>
Create test with new framework

Signed-off-by: Dmitry Prytkov <[email protected]>
Co-authored-by: Roman Sysoev <[email protected]>
Signed-off-by: Dmitry Prytkov <[email protected]>
@hayer969 hayer969 marked this pull request as draft December 30, 2025 09:49
@nevermarine nevermarine modified the milestones: v1.4.0, v1.5.0 Jan 23, 2026
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.

5 participants