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

Adds a CI Check to run CLI against Windows and Ubuntu; adds build:test-project as reusable fixture #4495

Merged
merged 27 commits into from
Feb 16, 2022

Conversation

thedavidprice
Copy link
Contributor

@thedavidprice thedavidprice commented Feb 16, 2022

Closes #4485

What's the point:

  • make test-project use more efficient
  • use test-project for CI
  • use test-project as a fixture for unit tests
  • remove CLI checks from E2E CI Workflow
  • add missing CLI checks to CI
  • replace telemetry-benchmarks workflow with this one

CLI checks

  • Need to run yarn rw dev and yarn rw serve: See Add smoke test for rw dev and rw serve commands #4259
  • How to handle rw setup command: tailwindcss, chakra-ui, auth, deploy, etc: they all fail even if using yarn dev <command> --cwd ... due to setup trying to install yarn workspace web add ... during the process
  • enable rw check: currently has a legitimate error (there's a createContact mutation, but not service)
  • enable rw type-check: throwing "gql missing" error, which is not reproducible locally.

Codemods for build:test-project

  • resolve yarn rw lint errors in built test-project
  • resolve missing createContact in Service
  • add prerender to NotFoundPage and HomePage

build:test-project option

  • --re-build-fixture: option to build new project at ./__fixtures__/test-project
    • typescript
    • latest published version of Redwood Packages
    • remove yarn.lock
    • probably need to build in /tmp outside directory and then copy back ('cause Yarn 1)
  • --copy-from-fixture: default=true, when running build:test-project use codebase at __fixtures/test-project to copy into target directory instead of creating codebase from scratch
  • determine a process about when to rebuild __fixtures__/test-project: breaking change, adding feature/code to test, new codemod, etc.?

publishing Redwood packages

  • should we rebuild __fixtures__/test-project each time we publish?
    • probably "no"
  • ==> or just update package versions (along with script "update-package-versions)?

@jtoar jtoar added release:chore This PR is a chore (means nothing for users) topic/ops-&-contributing-dx labels Feb 16, 2022
@thedavidprice thedavidprice changed the title Adds a CI Check to run CLI against Windows and Ubuntu Adds a CI Check to run CLI against Windows and Ubuntu; adds build:test-project as reusable fixture Feb 16, 2022
@jtoar
Copy link
Contributor

jtoar commented Feb 16, 2022

@thedavidprice I'm testing an action right now in another repo, I'll commit it here when it's ready.

@jtoar
Copy link
Contributor

jtoar commented Feb 16, 2022

@thedavidprice I got past the setup step. Reverted back to an action. Things are working!

I had to disable yarn rw type-check and yarn rw check. The error from yarn rw check seems legitimate (there's a createContact mutation, but not service), but I can't reproduce the error from yarn rw type-check, which is about gql missing.

@jtoar jtoar merged commit bce92f5 into main Feb 16, 2022
@jtoar jtoar deleted the dsp-ds-command-workflow-ci-including-windows branch February 16, 2022 12:45
@jtoar jtoar added this to the next-release milestone Feb 16, 2022
@thedavidprice
Copy link
Contributor Author

Thanks @jtoar 🚀

Lesson learned --> do it all in an Action 🤬

I've continued this work over here in #4500

@thedavidprice thedavidprice restored the dsp-ds-command-workflow-ci-including-windows branch February 16, 2022 16:33
@thedavidprice
Copy link
Contributor Author

@dac09 not sure if you still needed this branch to update your follow-on PR — I've restored it.

@dac09
Copy link
Collaborator

dac09 commented Feb 16, 2022

No all good :) thank you

@dac09 dac09 deleted the dsp-ds-command-workflow-ci-including-windows branch February 16, 2022 16:35
@thedavidprice thedavidprice modified the milestones: next-release, v0.46.0 Feb 18, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
release:chore This PR is a chore (means nothing for users) topic/ops-&-contributing-dx
Projects
No open projects
Status: Archived
Development

Successfully merging this pull request may close these issues.

[CI] Test Windows and all Command
4 participants