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

Migrate Module tests to Module repos #594

Closed
7 of 10 tasks
circlecube opened this issue Aug 4, 2023 · 2 comments
Closed
7 of 10 tasks

Migrate Module tests to Module repos #594

circlecube opened this issue Aug 4, 2023 · 2 comments
Assignees

Comments

@circlecube
Copy link
Member

circlecube commented Aug 4, 2023

Is your feature request related to a problem? Please describe.
Moving the test code into the module where the code lives will help manage tests from the source rather than having every test duplicated in each brand plugin.

The workflow for tagging a module update needs to include running tests locally to ensure they all pass, so that when the module update PR in the plugin runs the tests will pass and we can avoid a series of module releases that fix broken tests not found until the plugin PR is created.

Once tests are all moved to the module level we'll look at how we can automate the module PRs running the tests too. Perhaps we can use the blueprint plugin as a container or use a componentized environment for the module.

Describe the solution you'd like
The tests should be removed from the plugin and added to the module. The cypress config should also be updated to look for tests in the modules and add an environment variable for plugin-specific things like brand plugin id for urls. Any fixtures specific to the test should also be moved into the module.

Modules that have migrated:

  • CTB
  • Coming Soon
  • Staging
  • Marketplace (with premium plugins tab test)
  • Notifications

Modules that need tests migrated:

  • Onboarding

Modules that should have e2e tests written and added:

  • Ecommerce
  • Patterns
  • Help Center
  • Performance

Describe alternatives you've considered

Additional context

@circlecube circlecube self-assigned this Aug 4, 2023
@circlecube
Copy link
Member Author

I've created a PR for each press-1 module:
newfold-labs/wp-module-ctb#2
newfold-labs/wp-module-staging#9
newfold-labs/wp-module-coming-soon#8
newfold-labs/wp-module-marketplace#33
newfold-labs/wp-module-notifications#7

There is a PR housing the module updates and removal of test files from the plugin at:
#576 Here I'll update modules as they are released with test files and remove the appropriate spec files from the plugin.

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

No branches or pull requests

1 participant