Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Select targets to run tests on in GitHub Actions #5507

Merged
merged 1 commit into from
Nov 28, 2023

Conversation

dlon
Copy link
Member

@dlon dlon commented Nov 27, 2023

This lets us run tests on only a subset of supported OSes.

Fix DES-484.


This change is Reviewable

@dlon dlon force-pushed the gha-run-tests-on-os-subset branch 2 times, most recently from e1a3965 to c228c8d Compare November 27, 2023 17:05
@dlon dlon marked this pull request as ready for review November 27, 2023 17:06
Copy link

linear bot commented Nov 27, 2023

Copy link
Contributor

@MarkusPettersson98 MarkusPettersson98 left a comment

Choose a reason for hiding this comment

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

Reviewed 1 of 1 files at r1, all commit messages.
Reviewable status: all files reviewed, 3 unresolved discussions (waiting on @dlon)


.github/workflows/desktop-e2e.yml line 25 at r1 (raw file):

          else
            oses=$(printf '%s\n' "$oses" | jq . -R | jq . -s)
            selected=$(jq -cn --argjson oses "$oses" --argjson all "$all" '$all - ($all - $oses)')

jq -cn '$all - ($all - $oses)' will evaluate to simply $oses 😄
It should be possible to simplify the expression which is assigned to selected

Code quote:

selected=$(jq -cn --argjson oses "$oses" --argjson all "$all" '$all - ($all - $oses)')

.github/workflows/desktop-e2e.yml line 38 at r1 (raw file):

          else
            oses=$(printf '%s\n' "$oses" | jq . -R | jq . -s)
            selected=$(jq -cn --argjson oses "$oses" --argjson all "$all" '$all - ($all - $oses)')

dito

Code quote:

selected=$(jq -cn --argjson oses "$oses" --argjson all "$all" '$all - ($all - $oses)')

.github/workflows/desktop-e2e.yml line 51 at r1 (raw file):

          else
            oses=$(printf '%s\n' "$oses" | jq . -R | jq . -s)
            selected=$(jq -cn --argjson oses "$oses" --argjson all "$all" '$all - ($all - $oses)')

dito

Code quote:

selected=$(jq -cn --argjson oses "$oses" --argjson all "$all" '$all - ($all - $oses)')

Copy link
Member Author

@dlon dlon left a comment

Choose a reason for hiding this comment

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

Reviewable status: all files reviewed, 3 unresolved discussions (waiting on @MarkusPettersson98)


.github/workflows/desktop-e2e.yml line 25 at r1 (raw file):

Previously, MarkusPettersson98 (Markus Pettersson) wrote…

jq -cn '$all - ($all - $oses)' will evaluate to simply $oses 😄
It should be possible to simplify the expression which is assigned to selected

It's not the same as $oses. It only returns the intersection of the two

Copy link
Contributor

@MarkusPettersson98 MarkusPettersson98 left a comment

Choose a reason for hiding this comment

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

:lgtm:

Reviewable status: all files reviewed, 1 unresolved discussion (waiting on @dlon)


.github/workflows/desktop-e2e.yml line 25 at r1 (raw file):

Previously, dlon (David Lönnhager) wrote…

It's not the same as $oses. It only returns the intersection of the two

Yes, you are completely correct!

@dlon dlon force-pushed the gha-run-tests-on-os-subset branch 2 times, most recently from 00c893d to c0054bc Compare November 28, 2023 10:46
@dlon dlon force-pushed the gha-run-tests-on-os-subset branch from c0054bc to 63e4682 Compare November 28, 2023 10:47
@dlon dlon merged commit 63e4682 into main Nov 28, 2023
2 of 3 checks passed
@dlon dlon deleted the gha-run-tests-on-os-subset branch November 28, 2023 10:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants