ci: Migrate from CircleCI to GitHub Actions#7754
ci: Migrate from CircleCI to GitHub Actions#7754camdecoster wants to merge 36 commits intomasterfrom
Conversation
There was a problem hiding this comment.
@camdecoster It might be a good idea to keep this script, as a record of the source of these font files.
There was a problem hiding this comment.
I added a markdown file with the font source info.
|
@camdecoster Something to consider (as discussed): Using separate baseline images for the |
| const handler = (d) => { | ||
| Lib.clearThrottle(); | ||
| const isNode = d.points[0].hasOwnProperty('sourceLinks'); | ||
| const isExpectedType = (elType === 'node') ? isNode : !isNode; | ||
| if (!isExpectedType) { | ||
| gd.once(eventType, handler); | ||
| return; | ||
| } | ||
| resolve(d); | ||
| }); | ||
| } | ||
| gd.once(eventType, handler); |
There was a problem hiding this comment.
@camdecoster Can you explain this change? I can't quite get my head around it.
There was a problem hiding this comment.
I'm not sure why, but the test 'should not output hover/unhover event data when node.hoverinfo is skip' was returning a hover event for a link, causing the test to fail. This handler ignores those events (when appropriate) to get the test to pass. As we discussed, I'll run these changes with/without the node event turned off and see if the test is actually working with this handler.
| expect(newPosition.x).toBeCloseTo(pos[0], -1, 'x position ' + msg); | ||
| expect(newPosition.y).toBeCloseTo(pos[1], -1, 'y position ' + msg); |
There was a problem hiding this comment.
I'm a little surprised this change is needed, since I would expect the initial position to match even if the position after drag is a little different. How many pixels off is it?
There was a problem hiding this comment.
The viewport size needed to change for some tests to pass on GHA. That difference was enough that some of the other test results now changed. This is one such example.
| [0, 191, 'Personnel expenses'], | ||
| [0, 179, 'Other expenses'], |
There was a problem hiding this comment.
A little surprised by this one as well... two additional points selected seems like a significant change, more than just a slight pixel difference. I'm curious what the cause is. I realize it might not be a good use of time to dig too deeply into this one though.
There was a problem hiding this comment.
This is another example of the test results changing due to the viewport size change.
| @@ -2705,13 +2707,14 @@ describe('Test select box and lasso per trace:', function() { | |||
| assertPoints([ | |||
| [0, 331.5, 'Author: etpinard'], | |||
| [1, 53.5, 'Pull requests'], | |||
| [1, 15.5, 'Author: etpinard'], | |||
There was a problem hiding this comment.
Likewise, the points are spaced far enough apart on this one that I'm surprised by the change.
There was a problem hiding this comment.
This is another example of the test results changing due to the viewport size change.
This reverts commit b0348e9.
| NODE_VERSION: '18' | ||
|
|
||
| jobs: | ||
| detect-changes: |
There was a problem hiding this comment.
Could the paths: argument be used instead of this job?
| # Upload library uncompressed to allow for testing in REPLs | ||
| - uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7 | ||
| with: | ||
| retention-days: 7 |
There was a problem hiding this comment.
Longer retention will make our lives easier I think, we can reduce it if it becomes a problem (not sure if there is a total storage limit?)
| retention-days: 7 | |
| retention-days: 30 |
| run: npm run build | ||
|
|
||
| # Upload library uncompressed to allow for testing in REPLs | ||
| - uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7 |
There was a problem hiding this comment.
Add name to make it easier to find in the workflow results
| - uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7 | |
| - uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7 | |
| name: Upload built plotly.js |
| echo "Download the baseline images from the artifacts of this workflow run." | ||
| echo "Add the new images to 'test/image/baselines/' and commit them to this pull request." | ||
|
|
||
| - uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7 |
There was a problem hiding this comment.
| - uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7 | |
| - uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7 | |
| name: Upload differing images |
| Please note that image pixel comparison tests run on `ubuntu-latest` in GitHub Actions. | ||
| Therefore the final baselines may need updates. | ||
| This could simply be done by downloading the `baselines.tar` stored in the `ARTIFACTS` tab of `test-baselines` job (if the test failed). | ||
| This could simply be done by downloading the baseline images from the **Artifacts** section of the `test-baselines` job in the failed workflow run. |
There was a problem hiding this comment.
| This could simply be done by downloading the baseline images from the **Artifacts** section of the `test-baselines` job in the failed workflow run. | |
| To use the images generated by the CI job directly, you can download the baseline images from the "Upload failing images" step of the `test-baselines` job in the failed workflow run. |
Description
Migrate automated testing from CircleCI to GitHub Actions.
Closes #7732.
Changes
Testing
Notes