Fix/improve tests (#1052)

* Improve unit test condition.

* Improve/fix tests.
This commit is contained in:
Felix Fontein
2025-03-08 09:54:41 +01:00
committed by GitHub
parent ca7f3eb82f
commit fdb97428a3
27 changed files with 130 additions and 115 deletions
@@ -140,26 +140,26 @@
- assert:
that:
- pull_1_check is changed
- pull_1_check.actions | selectattr('status', 'eq', 'Pulling') | first
- (pull_1_check.actions | selectattr('status', 'eq', 'Pulling') | first) is truthy
- pull_1_check.warnings | default([]) | select('regex', 'Cannot parse event from ') | length == 0
- pull_1 is changed
- pull_1.actions | selectattr('status', 'eq', 'Pulling') | first
- (pull_1.actions | selectattr('status', 'eq', 'Pulling') | first) is truthy
- pull_1.warnings | default([]) | select('regex', 'Cannot parse event from ') | length == 0
- pull_2_check is not changed
- pull_2_check.warnings | default([]) | select('regex', 'Cannot parse event from ') | length == 0
- pull_2 is not changed
- pull_2.warnings | default([]) | select('regex', 'Cannot parse event from ') | length == 0
- pull_3_check is changed
- pull_3_check.actions | selectattr('status', 'eq', 'Pulling') | first
- (pull_3_check.actions | selectattr('status', 'eq', 'Pulling') | first) is truthy
- pull_3_check.warnings | default([]) | select('regex', 'Cannot parse event from ') | length == 0
- pull_3 is changed
- pull_3.actions | selectattr('status', 'eq', 'Pulling') | first
- (pull_3.actions | selectattr('status', 'eq', 'Pulling') | first) is truthy
- pull_3.warnings | default([]) | select('regex', 'Cannot parse event from ') | length == 0
- pull_4_check is changed
- pull_4_check.actions | selectattr('status', 'eq', 'Pulling') | first
- (pull_4_check.actions | selectattr('status', 'eq', 'Pulling') | first) is truthy
- pull_4_check.warnings | default([]) | select('regex', 'Cannot parse event from ') | length == 0
- pull_4 is not changed
- pull_4.actions | selectattr('status', 'eq', 'Pulling') | first
- (pull_4.actions | selectattr('status', 'eq', 'Pulling') | first) is truthy
- pull_4.warnings | default([]) | select('regex', 'Cannot parse event from ') | length == 0
- when: docker_compose_version is version('2.22.0', '<')
@@ -193,14 +193,14 @@
- assert:
that:
- pull_1_check is changed
- pull_1_check.actions | selectattr('status', 'eq', 'Pulling') | first
- (pull_1_check.actions | selectattr('status', 'eq', 'Pulling') | first) is truthy
- pull_1_check.warnings | default([]) | select('regex', 'Cannot parse event from ') | length == 0
- pull_1 is changed
- pull_1.actions | selectattr('status', 'eq', 'Pulling') | first
- (pull_1.actions | selectattr('status', 'eq', 'Pulling') | first) is truthy
- pull_1.warnings | default([]) | select('regex', 'Cannot parse event from ') | length == 0
- pull_2_check is changed
- pull_2_check.actions | selectattr('status', 'eq', 'Pulling') | first
- (pull_2_check.actions | selectattr('status', 'eq', 'Pulling') | first) is truthy
- pull_2_check.warnings | default([]) | select('regex', 'Cannot parse event from ') | length == 0
- pull_2 is not changed
- pull_2.actions | selectattr('status', 'eq', 'Pulling') | first
- (pull_2.actions | selectattr('status', 'eq', 'Pulling') | first) is truthy
- pull_2.warnings | default([]) | select('regex', 'Cannot parse event from ') | length == 0