action #98655
closedFix flaky coverage - lib/OpenQA/Worker/Job.pm size:M
Description
Observation¶
https://github.com/os-autoinst/openQA/pull/4205 is a "dependency" update PR which should really be unrelated to coverage changes but there is a report about a coverage drop
lib/OpenQA/Worker/Job.pm 99.55% <0.00%> (-0.15%) arrow_down
Acceptance criteria¶
- AC1: The problematic code path is covered consistently
Suggestions¶
As the uncovered line is
sub settings { shift->{_settings} }
- check where it should have been called an ensure it is called in tests.
- check the code path to the settings for bugs, maybe it's not called correctly/reliably
- mark the individual line as uncoverable? it doesn't look like e.g. an exit or busy loop, though (last resort)
Updated by livdywan about 3 years ago
- Subject changed from Fix flaky coverage - lib/OpenQA/Worker/Job.pm to Fix flaky coverage - lib/OpenQA/Worker/Job.pm size:M
- Description updated (diff)
- Status changed from New to Workable
Updated by mkittler about 3 years ago
- Status changed from Workable to In Progress
sub settings { shift->{_settings} }
is not covered according to the coverage report but there's no way that a full/successful test run would not execute that line. According to the coverage report, this line was also not covered before.
The line which has changed is actually log_error('Unable to make final image uploads. Maybe the web UI considers this job already dead.');
; only this line has the info "Your changes would remove coverage for this line.". So that's what I will focus on in this ticket.
Updated by mkittler about 3 years ago
Updated by mkittler about 3 years ago
- Status changed from In Progress to Feedback
The PR has been merged. By the way, the file has only two uncovered lines left. I guess it would make sense to add coverage for these right away as well.
Updated by mkittler about 3 years ago
Updated by mkittler about 3 years ago
- Status changed from Feedback to Resolved
Both PRs have been merged.