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

[testing workflows] Add workflow_call trigger in CI workflow - support daily and other types of runs #47612

Merged
merged 31 commits into from
May 22, 2024

Conversation

adimoldovan
Copy link
Contributor

@adimoldovan adimoldovan commented May 20, 2024

Submission Review Guidelines:

Changes proposed in this Pull Request:

Prep work for #47532

Adds the workflow_call trigger for ci.yml. This makes it possible to trigger the jobs defined in ci.yml by other events.

Instead of defining all the possible triggers in ci.yml directly, I think it would be cleaner to have other workflows that are triggered by those events (e.g. cron) and have those workflows call ci.yml with specific inputs (e.g. daily-e2e, release-checks, etc.).

This PR adds the tests-daily-run.yml workflow which will run on a schedule and call ci.yml with the daily-e2e input. The ci-jobs utility will return a jobs matrix with only those jobs configured to run on daily-e2e event - currently only Core e2e tests - Gutenberg.

I only configured the Gutenberg job as an example and to test it. All other daily or release test projects will be configured in follow-up PRs and smoke-test-daily.yml and
smoke-test-release.yml will be deprecated.

I had to update the events for all test jobs in all projects files so that they will not run on daily runs. I did not update the lint jobs because they are restricted at workflow level since #47652.

How to test the changes in this Pull Request:

Using the WooCommerce Testing Instructions Guide, include your detailed testing instructions:

  • Tested with this run, where ci.yml was triggered with a workflow_call event by tests-daily-run.yml with inputs.trigger=daily-e2e. Only the e2e tests with Gutenberg ran (ignore the lint jobs, they will not run once [ci] Only run lint jobs on pull_request event #47652 is merged). The tests are expected to fail, you can ignore the results.
  • Check code changes.
  • CI jobs run as before.

@github-actions github-actions bot added the focus: monorepo infrastructure Issues and PRs related to monorepo tooling. label May 20, 2024
Copy link
Contributor

github-actions bot commented May 20, 2024

Test using WordPress Playground

The changes in this pull request can be previewed and tested using a WordPress Playground instance.
WordPress Playground is an experimental project that creates a full WordPress instance entirely within the browser.

Test this pull request with WordPress Playground.

Note that this URL is valid for 30 days from when this comment was last updated. You can update it by closing/reopening the PR or pushing a new commit.

@github-actions github-actions bot added the plugin: woocommerce Issues related to the WooCommerce Core plugin. label May 20, 2024
@github-actions github-actions bot added the focus: e2e tests Issues related to e2e tests label May 22, 2024
@adimoldovan adimoldovan self-assigned this May 22, 2024
@adimoldovan adimoldovan changed the title [testing workflows] Add workflow_call support in CI [testing workflows] Add support for daily runs in CI workflow May 22, 2024
@github-actions github-actions bot added package: @woocommerce/components issues related to @woocommerce/components package: @woocommerce/csv-export issues related to @woocommerce/csv-export package: @woocommerce/currency issues related to @woocommerce/currency package: @woocommerce/customer-effort-score issues related to @woocommerce/customer-effort-score package: @woocommerce/data issues related to @woocommerce/data package: @woocommerce/date issues related to @woocommerce/date package: @woocommerce/experimental issues related to @woocommerce/experimental package: @woocommerce/explat issues related to @woocommerce/explat package: @woocommerce/navigation issues related to @woocommerce/navigation package: @woocommerce/number issues related to @woocommerce/number package: @woocommerce/onboarding issues related to @woocommerce/onboarding labels May 22, 2024
@adimoldovan adimoldovan changed the title [testing workflows] Add support for daily runs in CI workflow [testing workflows] Add workflow_call trigger in CI workflow - support daily and other types of runs May 22, 2024
@adimoldovan adimoldovan marked this pull request as ready for review May 22, 2024 14:25
@woocommercebot woocommercebot requested a review from a team May 22, 2024 14:27
Copy link
Contributor

Hi , @woocommerce/vortex

Apart from reviewing the code changes, please make sure to review the testing instructions as well.

You can follow this guide to find out what good testing instructions should look like:
https://github.com/woocommerce/woocommerce/wiki/Writing-high-quality-testing-instructions

use: { ...devices[ 'Desktop Chrome' ] },
testIgnore:
/.*smoke-tests\/*|.*js-file-monitor\/*|.*admin-tasks\/*|.*activate-and-setup\/*|.*admin-analytics\/*|.*admin-marketing\/*/,
},
Copy link
Contributor

Choose a reason for hiding this comment

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

Nice use of projects here. Think this'll be a great way to segment the different types of tests we need to run.

@lanej0 lanej0 merged commit 13ab900 into trunk May 22, 2024
77 checks passed
@lanej0 lanej0 deleted the ci/add-workflow-call-event branch May 22, 2024 18:04
@github-actions github-actions bot added this to the 9.0.0 milestone May 22, 2024
@github-actions github-actions bot added the needs: analysis Indicates if the PR requires a PR testing scrub session. label May 22, 2024
@Stojdza Stojdza added status: analysis complete Indicates if a PR has been analysed by Solaris and removed needs: analysis Indicates if the PR requires a PR testing scrub session. labels May 22, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
focus: e2e tests Issues related to e2e tests focus: monorepo infrastructure Issues and PRs related to monorepo tooling. package: @woocommerce/api Issues related to @woocommerce/api package. package: @woocommerce/components issues related to @woocommerce/components package: @woocommerce/csv-export issues related to @woocommerce/csv-export package: @woocommerce/currency issues related to @woocommerce/currency package: @woocommerce/customer-effort-score issues related to @woocommerce/customer-effort-score package: @woocommerce/data issues related to @woocommerce/data package: @woocommerce/date issues related to @woocommerce/date package: @woocommerce/experimental issues related to @woocommerce/experimental package: @woocommerce/explat issues related to @woocommerce/explat package: @woocommerce/navigation issues related to @woocommerce/navigation package: @woocommerce/number issues related to @woocommerce/number package: @woocommerce/onboarding issues related to @woocommerce/onboarding plugin: woocommerce Issues related to the WooCommerce Core plugin. status: analysis complete Indicates if a PR has been analysed by Solaris
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants