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

Require one of the lxd or lxd-installer debs or the lxd snap for the virtualization tests. (BugFix) #1181

Merged
merged 1 commit into from
Apr 17, 2024

Conversation

bladernr
Copy link
Collaborator

@bladernr bladernr commented Apr 12, 2024

Description

Noble does not provide the lxd snap by default now in the server images, instead it provides a wrapper called lxd-installer that triggers the snap install the first time a user tries using either the lxc or lxd commands.

The jobs were not looking for the lxd-installer package, instead they were looking for the lxd snap or the old lxd package. This changes the constraints so that the jobs will run if only lxd-installer is present (on noble server) . In this case, the 'lxd init' commands that virtualization.py runs will trigger the snap install on server, and then tests proceed as expected.

Added a check to run the job if lxd-installer is on the system, since on Noble, the lxd snap and deb will not be there at first.

Resolved issues

#1022
CHECKBOX-1275

Documentation

NO docs changes needed.

Tests

Manually modified jobs.pxu on a fresh noble install to add the package lxd-installer to the requires section for the virtualization jobs.

Ran test-virtualization to call both lxd and lxdvm tests.

Before changes, the tests are skipped because the lxd snap is not installed.
After the changes, the tests are executed.

@bladernr bladernr linked an issue Apr 12, 2024 that may be closed by this pull request
Copy link

codecov bot commented Apr 12, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 43.19%. Comparing base (268c743) to head (d831c04).
Report is 1 commits behind head on main.

Additional details and impacted files
@@           Coverage Diff           @@
##             main    #1181   +/-   ##
=======================================
  Coverage   43.19%   43.19%           
=======================================
  Files         356      356           
  Lines       38653    38653           
  Branches     6561     6561           
=======================================
  Hits        16697    16697           
  Misses      21293    21293           
  Partials      663      663           
Flag Coverage Δ
provider-base 16.24% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@bladernr
Copy link
Collaborator Author

Why is this failing on "black formatting"? I pulled a updated copy of checkbox, edited a branch and pushed it, and the black formatting thing seems to be complaining about things I didn't even touch.

@bladernr bladernr force-pushed the 1022-virtualization-tests-fail-to-run-on-noble branch from 11050c0 to d831c04 Compare April 15, 2024 13:34
@bladernr
Copy link
Collaborator Author

Saw @pieqq 's update and rebased to fix the formatting issues.

Copy link
Contributor

@kissiel kissiel left a comment

Choose a reason for hiding this comment

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

Makes sense! +1

@kissiel kissiel merged commit 6f0ca4e into main Apr 17, 2024
14 checks passed
@kissiel kissiel deleted the 1022-virtualization-tests-fail-to-run-on-noble branch April 17, 2024 16:56
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.

Virtualization Tests Fail to Run on Noble
2 participants