-
Notifications
You must be signed in to change notification settings - Fork 4
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
Revamp GitHub workflows using Ember.js native implementation #144
Conversation
effd1e4
to
0d61c5b
Compare
|
||
env: | ||
NODE_VERSION: '12.x' | ||
NODE_VERSION: '12' |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The syntax 12
is enough if we just want to use the lastest major version.
|
||
- name: Lint | ||
run: yarn lint | ||
- uses: actions/checkout@v2 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This Action already uses fetch-depth: 1
as its default:
https://github.com/actions/checkout/blob/v2.3.4/README.md?plain=1#L92-L94
uses: actions/setup-node@v2 | ||
with: | ||
node-version: ${{ env.NODE_VERSION }} | ||
cache: yarn |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This allows us to let the Action handles the caching of dependencies:
https://github.com/actions/setup-node/blob/v2.4.1/docs/advanced-usage.md?plain=1#L45-L56
with: | ||
node-version: '${{ env.NODE_VERSION }}' | ||
- name: Run Tests | ||
run: yarn run test:ember |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We used to run the following command: (source)
run: yarn test:ember --launch chrome
( ⬆️. because strategy.browser
only has the value chrome
)
I am not convinced --launch chrome
is really needed, can someone confirm?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It seems useful when you have multiple browsers in testem.js
launch_in_ci
prop and you only want to run your test on one specific browser, as we only have Chrome
in testem.js
launch_in_ci
prop, it seems ok to remove it
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Noice, thanks.
|
||
- name: Run Tests | ||
run: yarn run test:ember |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Answer provided, see the related link ✅ .
with: | ||
node-version: '${{ env.NODE_VERSION }}' | ||
- name: Run Tests | ||
run: yarn run test:ember |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It seems useful when you have multiple browsers in testem.js
launch_in_ci
prop and you only want to run your test on one specific browser, as we only have Chrome
in testem.js
launch_in_ci
prop, it seems ok to remove it
|
||
try-scenarios: | ||
name: Tests - ${{ matrix.ember-try-scenario }} | ||
name: ${{ matrix.try-scenario }} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
As we are updating this file, wondering if we should add timeout-minutes option, to avoid having issues with some scenarios running for 360 minutes (default value) because there is an issue in tests and no output is generated, see https://github.com/peopledoc/ember-cli-embedded/runs/3443628551?check_suite_focus=true for example
Was happening mainly for Beta/Canary but could be a "security" for "ember-release" scenario 🤷♂️
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Indeed, I actually thought about it yesterday and forgot to add it, thanks.
To make them match with the names used in the GitHub workflows.
This was removed in `ember-cli` v3.20.0: ember-cli/ember-addon-output@1ed3342
I also moved the `needs` statements right after the `name` statements to sort them.
b637c7d
to
cbe621c
Compare
Inspired from: DazzlingFugu/ember-cli-embedded#144 Ember's implementation: https://github.com/ember-cli/ember-addon-output/blob/v4.0.0-beta.1/.github/workflows/ci.yml ci: add tests for Embroider compatibility
CI
Reset GitHub workflow file to Ember.js native implementation (#144)
Ember.js implementation:
https://github.com/ember-cli/ember-addon-output/blob/v4.0.0-beta.1/.github/workflows/ci.yml
We used to manually handle the caching of dependencies while
actions/setup-node
natively handles it, with a few parameters, making our life easier.One tiny addition compared to Ember.js implementation: jobs got a timeout of 20 minutes to avoid burning the default limit of 6 hours.
Remove scenario
ember-default
inember-try
(#144)This scenario has been removed in
ember-cli
v3.20.0:ember-cli/ember-addon-output@1ed3342
Update name of
ember-try
scenarios (#144)To make them match with Ember.js native implementation and with the names usually used in the Ember.js ecosystem.
Fixes
Fix npm-script
lint
inpackage.json
(#144)See https://github.com/ember-cli/ember-cli/pull/9500/files