chore(gh): optimize GH actions ci workflow#21859
Conversation
✅ Deploy Preview for v11-carbon-react ready!Built without sensitive environment variables
To edit notification comments on pull requests, go to your Netlify project configuration. |
✅ Deploy Preview for v11-carbon-web-components ready!
To edit notification comments on pull requests, go to your Netlify project configuration. |
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #21859 +/- ##
==========================================
- Coverage 94.42% 94.40% -0.03%
==========================================
Files 536 536
Lines 43673 43673
Branches 6272 6248 -24
==========================================
- Hits 41239 41228 -11
- Misses 2295 2306 +11
Partials 139 139
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
maradwan26
left a comment
There was a problem hiding this comment.
LGTM! Tests are passing 🎊 Thanks for doing this
…st/gh-workflow-ubuntu-latest-fixes
…st/gh-workflow-ubuntu-latest-fixes
…nylam/carbon into test/gh-workflow-ubuntu-latest-fixes
| test('set of buttons fluid 1 wide @vrt', async ({ page }) => { | ||
| await visitStory(page, { | ||
| component: 'Button', | ||
| id: 'components-button-set-of-buttons--fluid', | ||
| theme, | ||
| args: { | ||
| 'Fluid buttons': '0', | ||
| 'Container width': '800px', | ||
| }, | ||
| }); | ||
| await snapshot(page, { | ||
| component: 'Button', | ||
| id: 'components-button-set-of-buttons--fluid', | ||
| theme, | ||
| }); | ||
| }); | ||
|
|
||
| test('set of buttons fluid 1 wide ghost @vrt', async ({ page }) => { | ||
| await visitStory(page, { | ||
| component: 'Button', | ||
| id: 'components-button-set-of-buttons--fluid', | ||
| theme, | ||
| args: { | ||
| 'Fluid buttons': '3', | ||
| 'Container width': '800px', | ||
| }, | ||
| }); | ||
| await snapshot(page, { | ||
| component: 'Button', | ||
| id: 'components-button-set-of-buttons--fluid', | ||
| theme, | ||
| }); | ||
| }); | ||
|
|
||
| test('set of buttons fluid 1 narrow @vrt', async ({ page }) => { | ||
| await visitStory(page, { | ||
| component: 'Button', | ||
| id: 'components-button-set-of-buttons--fluid', | ||
| theme, | ||
| args: { | ||
| 'Fluid buttons': '0', | ||
| 'Container width': '280px', | ||
| }, | ||
| }); | ||
| await snapshot(page, { | ||
| component: 'Button', | ||
| id: 'components-button-set-of-buttons--fluid', | ||
| theme, | ||
| }); | ||
| }); | ||
|
|
||
| test('set of buttons fluid 2 wide @vrt', async ({ page }) => { | ||
| await visitStory(page, { | ||
| component: 'Button', | ||
| id: 'components-button-set-of-buttons--fluid', | ||
| theme, | ||
| args: { | ||
| 'Fluid buttons': '4', | ||
| 'Container width': '800px', | ||
| }, | ||
| }); | ||
| await snapshot(page, { | ||
| component: 'Button', | ||
| id: 'components-button-set-of-buttons--fluid', | ||
| theme, | ||
| }); | ||
| }); | ||
|
|
||
| test('set of buttons fluid 2 wide ghost @vrt', async ({ page }) => { | ||
| await visitStory(page, { | ||
| component: 'Button', | ||
| id: 'components-button-set-of-buttons--fluid', | ||
| theme, | ||
| args: { | ||
| 'Fluid buttons': '5', | ||
| 'Container width': '800px', | ||
| }, | ||
| }); | ||
| await snapshot(page, { | ||
| component: 'Button', | ||
| id: 'components-button-set-of-buttons--fluid', | ||
| theme, | ||
| }); | ||
| }); | ||
|
|
||
| test('set of buttons fluid 2 narrow @vrt', async ({ page }) => { | ||
| await visitStory(page, { | ||
| component: 'Button', | ||
| id: 'components-button-set-of-buttons--fluid', | ||
| theme, | ||
| args: { | ||
| 'Fluid buttons': '4', | ||
| 'Container width': '320px', | ||
| }, | ||
| }); | ||
| await snapshot(page, { | ||
| component: 'Button', | ||
| id: 'components-button-set-of-buttons--fluid', | ||
| theme, | ||
| }); | ||
| }); | ||
|
|
||
| test('set of buttons fluid 3 wide @vrt', async ({ page }) => { | ||
| await visitStory(page, { | ||
| component: 'Button', | ||
| id: 'components-button-set-of-buttons--fluid', | ||
| theme, | ||
| args: { | ||
| 'Fluid buttons': '6', | ||
| 'Container width': '800px', | ||
| }, | ||
| }); | ||
| await snapshot(page, { | ||
| component: 'Button', | ||
| id: 'components-button-set-of-buttons--fluid', | ||
| theme, | ||
| }); | ||
| }); | ||
|
|
||
| test('set of buttons fluid 3 wide ghost @vrt', async ({ page }) => { | ||
| await visitStory(page, { | ||
| component: 'Button', | ||
| id: 'components-button-set-of-buttons--fluid', | ||
| theme, | ||
| args: { | ||
| 'Fluid buttons': '7', | ||
| 'Container width': '800px', | ||
| }, | ||
| }); | ||
| await snapshot(page, { | ||
| component: 'Button', | ||
| id: 'components-button-set-of-buttons--fluid', | ||
| theme, | ||
| }); | ||
| }); | ||
|
|
||
| test('set of buttons fluid 3 narrow @vrt', async ({ page }) => { | ||
| await visitStory(page, { | ||
| component: 'Button', | ||
| id: 'components-button-set-of-buttons--fluid', | ||
| theme, | ||
| args: { | ||
| 'Fluid buttons': '6', | ||
| 'Container width': '500px', | ||
| }, | ||
| }); | ||
| await snapshot(page, { | ||
| component: 'Button', | ||
| id: 'components-button-set-of-buttons--fluid', | ||
| theme, | ||
| }); | ||
| }); |
There was a problem hiding this comment.
How are the non-default fluid ButtonSet layouts covered after removing the Playwright cases for narrow and wide container widths, as well as the alternate button count and button kind combinations? The remaining Storybook coverage appears limited to the default Fluid story state, so I don’t see an equivalent check for those arg driven layouts. Just want to ensure a regression isn't going to slip through, though I may be missing something.
There was a problem hiding this comment.
They are all now handled in Chromatic. All the removed e2e Playwright tests were snapshot-only. They called snapsshotStory() for Percy snapshots. No assertions for behavior, DOM structure, etc. It was only to generate the visual pixel comparison that got updated to Percy. That is all handled on Chromatic's side now.
We'll need to add the missing Storybook stories for fluid ButtonSet variants. I'll create a separate issue, since that isn't the purpose of this PR.
Edit: tracked in #21889.
|
Hey there! v11.104.0 was just released that references this issue/PR. |
This introduces several optimizations to the
CIGitHub workflow in an attempt to get back onto theubuntu-latestrunners rather than the customized larger ones.The biggest change is removing
examples/*from the workspace build pipeline. These example packages (custom-theme,class-prefix,id-prefix, etc) run full Vite builds, each bundling@carbon/reactwith all IBM Plex font variants, in parallel duringlerna run build. Most importantly, they do not consume workspace packages, instead pulling the latest published version from NPM. Unless there is a historical workflow/pipeline I'm missing about these packages, they provide no value in determining local package health.Additionally, an
avt-buildjob was added, which extracts the build process from theavt-runnerjobs. Each runner shard ran a build, duplicating it 4x.I have another branch which refactors the icon build pipeline to write directly to disk during builds rather than storing them in memory (~11k icons and pictograms). That branch includes the changes here and all CI jobs pass on my fork using the default
ubuntu-latestrunner.I don't want to introduce too many changes in one PR, so I'm going to test if these changes alone will allow CI to pass on the default runner. If not I'll create a draft and test with the other one (icons build refactor).
Changelog
New
format/lintjobsrestore-keysacross all jobsavt-buildjob to build Yarn + Storybook artifactsChanged
--puppeteerflag removed and now defined inweb-test-runner.config.mjsNODE_OPTIONSmemory limit to avt-runner build stepsavt-runnerjob and placed in dedicatedavt-buildjob (runs once)Removed
fetch-depthinflag-agents-md-changesexamples/*removed from workspace build pipelineTesting / Reviewing
The project should build and all CI/CD workflows should pass.
PR Checklist
As the author of this PR, before marking ready for review, confirm you:
More details can be found in the pull request guide