Skip to content
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -91,7 +91,7 @@ function suite() {
TESTS="$(ssh "${SSHOPTS[@]}" "root@${IP}" openshift-tests run --dry-run --provider "${TEST_PROVIDER}" "${TEST_SUITE}")" &&
echo "${TESTS}" | grep -v "${TEST_SKIPS}" >/tmp/tests &&
echo "Skipping tests:" &&
echo "${TESTS}" | grep "${TEST_SKIPS}" || { exit_code=$?; echo 'Error: no tests were found matching the TEST_SKIPS regex:'; echo "$TEST_SKIPS"; return $exit_code; } &&
echo "${TESTS}" | grep "${TEST_SKIPS}" || { echo 'Error: no tests were found matching the TEST_SKIPS regex:'; echo "$TEST_SKIPS"; } &&

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

I think all of the &&s are unnecessary now, since this line always succeeds. It'd be significantly easier to read without them.
Also it's a bit weird to print 'Error' for something that isn't actually an error.

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

I totally agree all of your comments @zaneb. Our intention was to be similar with other workflows in here

echo "${TESTS}" | grep "${TEST_SKIPS}" || { exit_code=$?; echo 'Error: no tests were found matching the TEST_SKIPS regex:'; echo "$TEST_SKIPS"; return $exit_code; } &&

But I think, we can remove && and change the message from Error to something Info.

What do you think @andfasano ?

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Agree, but given that our long-term goal is to adopt directly the openshift-e2e-test step (and abandon baremetalds-e2-test one - also PR #19987 goes in that direction), any discrepancy - not baremetal specific - introduced now will make more painful to merge our changes into the openshift-e2e-test when we'll be ready to do it.
So in this PR I'll stick as much as possible closer to the openshift-e2e-test step for whatever is not baremetal specific - and eventually address later any improvement directly in that step once we'll get it.

TEST_ARGS="${TEST_ARGS:-} --file /tmp/tests"
fi

Expand Down