Skip to content

Commit

Permalink
Merge pull request #678 from henrywang/error_fix
Browse files Browse the repository at this point in the history
test: Error fix
  • Loading branch information
cgwalters authored Jul 15, 2024
2 parents e1db50f + 4858190 commit 42fe361
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 28 deletions.
1 change: 0 additions & 1 deletion tests/booted/002-test-image-pushpull-upgrade.nu
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,6 @@ def initial_build [] {
let td = mktemp -d
cd $td

do --ignore-errors { podman image rm localhost/bootc o+e>| ignore }
bootc image copy-to-storage
let img = podman image inspect localhost/bootc | from json

Expand Down
32 changes: 5 additions & 27 deletions tests/e2e/playbooks/rollback.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -21,35 +21,13 @@
wait_for_connection:
delay: 30

- name: check bootc status
command: bootc status
ignore_errors: true
become: true

- name: rollback checking
block:
- name: get booted cachedupdate imageDigest
shell: bootc status --json | jq -r '.status.booted.cachedUpdate.imageDigest'
register: result_booted_cachedupdate_digest
become: true

- name: get rollback image digest
shell: bootc status --json | jq -r '.status.rollback.image.imageDigest'
register: result_rollback_image_digest
become: true

- name: check booted cachedUpdate and rollback image digest
block:
- assert:
that:
- result_booted_cachedupdate_digest.stdout == result_rollback_image_digest.stdout
fail_msg: "rollback failed"
success_msg: "rollback passed"
always:
- set_fact:
total_counter: "{{ total_counter | int + 1 }}"
rescue:
- name: failed count + 1
set_fact:
failed_counter: "{{ failed_counter | int + 1 }}"
when:
- air_gapped_dir | default('') == ""

- name: check installed package
shell: rpm -qa | sort
register: result_packages
Expand Down

0 comments on commit 42fe361

Please sign in to comment.