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 CI config to CircleCI v2 #212

Merged
merged 6 commits into from
Dec 7, 2018
Merged

Migrate CI config to CircleCI v2 #212

merged 6 commits into from
Dec 7, 2018

Conversation

wtho
Copy link
Collaborator

@wtho wtho commented Dec 6, 2018

CircleCI v1 is no longer supported and will stop working at all after August

Read more at circleci.com/sunset1-0

This PR contains the new config. It runs inside a node docker image instead of a fully fledged EC2 instance - so it is faster to setup and has yarn preinstalled.

command: |
yarn test:ci
- run:
name: Test Example App
Copy link
Owner

Choose a reason for hiding this comment

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

I think these two (test example and library) can go into workflows. I like to use this as a reference: https://github.com/callstack/react-native-paper/blob/master/.circleci/config.yml

Copy link
Collaborator Author

@wtho wtho Dec 6, 2018

Choose a reason for hiding this comment

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

Yeah, had them first put it in one step, but I preferred the immediate overview in the circleci-panel, in which part of the app the tests would fail. See this example

If you prefer them to be summarized, I can reduce them to one step.

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Oh now I got you, overlooked workflows
Will set that up 😄

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Ok, so I made it work.
The overview is more extendable and tests run parallel, but currentlly we lose about 30s for not running in one workspace (workspace has to be persisted and attached between different jobs).

I still prefer it, as it gives a better overview, especially if we might later choose to add linting, generating docs, ... (see workflow example from react-native-paper)

@wtho
Copy link
Collaborator Author

wtho commented Dec 6, 2018

CircleCI has to be configured differently for this repo itself to run the tests, I hoped it would auto-detect the config and the version.

This means open PRs will have to include this config as well or they will not run the tests anymore after CircleCI was configured to use v2 for this repo.

@thymikee thymikee changed the base branch from master to release/7 December 6, 2018 23:39
@thymikee
Copy link
Owner

thymikee commented Dec 6, 2018

I've pointed it to release/7 branch for now, maybe it will kick in once we merge into a branch on this repo.

.circleci/config.yml Outdated Show resolved Hide resolved
.circleci/config.yml Outdated Show resolved Hide resolved
* Moved example dependency installation in test-example
* Added caching for test dependencies
* Picked shorter names for jobs
* Updated executor to use node:11
@thymikee thymikee changed the base branch from release/7 to master December 7, 2018 15:35
@thymikee thymikee merged commit 52a4878 into thymikee:master Dec 7, 2018
@ahnpnl ahnpnl added this to the 7.0.0 milestone Dec 13, 2018
thymikee added a commit that referenced this pull request Jan 26, 2019
* origin/master:
  Upgraded ts-jest version. (#219)
  docs: add astTransformers in configuration example (#218)
  feat: Import jest-zone-patch (#214)
  chore: Migrate CI config to CircleCI v2 (#212)
  Transform templateUrl, styleUrls and styles everywhere (#211)
  feat: adjust semver range of jest-zone-patch (#209)
  Adjust CHANGELOG (#208)
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.

None yet

3 participants