Skip to content

Commit 66abb93

Browse files
committed
Bump version and fix SUCCESS_DATA list
Signed-off-by: Petr "Stone" Hracek <phracek@redhat.com>
1 parent 179fb33 commit 66abb93

6 files changed

Lines changed: 34 additions & 8 deletions

File tree

‎.github/workflows/build-and-push.yml‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ jobs:
1919
registry_username: ${{ secrets.QUAY_IMAGE_SCLORG_BUILDER_USERNAME }}
2020
registry_token: ${{ secrets.QUAY_IMAGE_SCLORG_BUILDER_TOKEN }}
2121
dockerfile: Dockerfile.daily-tests
22-
tag: "0.10.7"
22+
tag: "0.10.8"
2323
image_name: "upstream-daily-tests"
2424
quay_application_token: ${{ secrets.QUAY_IMAGE_SCLORG_UPDATE_DESC }}
2525

@@ -31,6 +31,6 @@ jobs:
3131
registry_username: ${{ secrets.QUAY_IMAGE_SCLORG_BUILDER_USERNAME }}
3232
registry_token: ${{ secrets.QUAY_IMAGE_SCLORG_BUILDER_TOKEN }}
3333
dockerfile: Dockerfile.eol-checker
34-
tag: "0.10.7"
34+
tag: "0.10.8"
3535
image_name: "upstream-eol-checker"
3636
quay_application_token: ${{ secrets.QUAY_IMAGE_SCLORG_UPDATE_DESC }}

‎Dockerfile.daily-tests‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ FROM quay.io/fedora/fedora:42
22

33
ENV SHARED_DIR="/var/ci-scripts" \
44
VERSION="42" \
5-
RELEASE_UPSTREAM="0.10.7" \
5+
RELEASE_UPSTREAM="0.10.8" \
66
UPSTREAM_TMT_REPO="https://github.com/sclorg/sclorg-testing-farm" \
77
UPSTREAM_TMT_DIR="sclorg-testing-farm" \
88
HOME="/home/nightly" \

‎Dockerfile.eol-checker‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
FROM quay.io/fedora/fedora:42
22

33
ENV VERSION="42" \
4-
RELEASE_UPSTREAM="0.10.7" \
4+
RELEASE_UPSTREAM="0.10.8" \
55
HOME="/home/eol-checker" \
66
SUMMARY="EOL checker for SCL org projects" \
77
DESCRIPTION="This image is used to run EOL checker for SCL org projects in CI." \

‎daily-tests/daily_tests/daily_nightly_tests_report.py‎

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -346,9 +346,9 @@ def collect_data(self):
346346
self.store_tmt_logs_to_dict(
347347
path_dir=path_dir, test_case=test_case, is_failed=False
348348
)
349-
self.data_dict["SUCCESS_DATA"].extend(
350-
[(test_case, str(f), str(f.name)) for f in success_logs]
351-
)
349+
for f in success_logs:
350+
print(f"Success log for {test_case} is: {f}")
351+
self.data_dict["SUCCESS_DATA"].append((test_case, str(f), str(f.name)))
352352
continue
353353
print(f"Failed containers are for {test_case} are: {failed_containers}")
354354
failed_tests = True
@@ -429,7 +429,7 @@ def generate_success_containers(self):
429429
"""
430430
Generate email body for successful containers.
431431
"""
432-
print("GENERATE SUCCESS CONTAINERS")
432+
print(f"GENERATE SUCCESS CONTAINERS {self.data_dict['SUCCESS_DATA']}")
433433
for test_case, cont_path, log_name in self.data_dict["SUCCESS_DATA"]:
434434
if os.path.exists(log_name):
435435
paste_bin_file = f"{cont_path}.txt"

‎daily-tests/tests/test_reports.py‎

Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -183,9 +183,34 @@ def test_collect_data_full_success_when_no_failed_logs(self, collect_report):
183183

184184
assert collect_report.full_success is True
185185
assert collect_report.data_dict["SUCCESS"] == ["fedora-test"]
186+
assert collect_report.data_dict["SUCCESS_DATA"] == []
186187
assert collect_report.data_dict["tmt"]["tmt_running"] == []
187188
assert collect_report.data_dict["tmt"]["tmt_failed"] == []
188189

190+
def test_collect_data_records_success_data_for_upstream_logs(self, collect_report):
191+
collect_report.args.upstream_tests = True
192+
case_dir = collect_report.reports_dir / "fedora-test"
193+
(case_dir / "results").mkdir(parents=True)
194+
success_log = case_dir / "success.log"
195+
success_log.write_text("success", encoding="utf-8")
196+
second_case_dir = collect_report.reports_dir / "rhel-test"
197+
(second_case_dir / "results").mkdir(parents=True)
198+
second_success_log = second_case_dir / "success.log"
199+
second_success_log.write_text("success", encoding="utf-8")
200+
collect_report.available_test_case = {
201+
("fedora-test", "nightly-fedora", "Fedora test results:"),
202+
("rhel-test", "nightly-rhel", "RHEL test results:"),
203+
}
204+
205+
collect_report.collect_data()
206+
207+
assert sorted(collect_report.data_dict["SUCCESS_DATA"]) == sorted(
208+
[
209+
("fedora-test", str(success_log), "success.log"),
210+
("rhel-test", str(second_success_log), "success.log"),
211+
]
212+
)
213+
189214
def test_collect_data_records_failed_container_logs(self, collect_report):
190215
case_dir = collect_report.reports_dir / "fedora-test"
191216
log_file = case_dir / "results" / "ns" / "failed.log"

‎tox.ini‎

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@ commands = python3 -m pytest --color=yes -v --cov=daily_tests --cov-report=xml:c
77
deps =
88
pytest
99
pytest-cov
10+
flexmock
1011
PyYAML
1112
requests
1213
xmltodict

0 commit comments

Comments
 (0)