From b410d05d7e3fa89434a1188db8650489f4b9740f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ga=C3=ABtan=20Maisse?= Date: Sun, 31 Oct 2021 18:23:00 +0100 Subject: [PATCH 1/4] refactor: add comment to fix eslint error --- lib/components/src/bar/button.stories.tsx | 1 + 1 file changed, 1 insertion(+) diff --git a/lib/components/src/bar/button.stories.tsx b/lib/components/src/bar/button.stories.tsx index 6de125f1d3bb..492e8f4177e2 100644 --- a/lib/components/src/bar/button.stories.tsx +++ b/lib/components/src/bar/button.stories.tsx @@ -8,6 +8,7 @@ export default { title: 'Basics/IconButton', }; +// eslint-disable-next-line no-underscore-dangle export const _IconButton = () => ( From e835a89ab9fe788642518c1f54b19e0d8c7ffa50 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ga=C3=ABtan=20Maisse?= Date: Sun, 31 Oct 2021 18:29:15 +0100 Subject: [PATCH 2/4] fix: update Preact preset filename --- app/preact/preset.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/preact/preset.js b/app/preact/preset.js index 4496115b389c..324b0db8eda2 100644 --- a/app/preact/preset.js +++ b/app/preact/preset.js @@ -1 +1 @@ -module.exports = require('./dist/cjs/server/framework-preset-babel-preact'); +module.exports = require('./dist/cjs/server/framework-preset-preact'); From d363da79264c65fa82c8a8920b178d2f02829d41 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ga=C3=ABtan=20Maisse?= Date: Sun, 31 Oct 2021 18:59:57 +0100 Subject: [PATCH 3/4] e2e: skip source snippet cypress test with @storybook/html --- cypress/generated/addon-docs.spec.ts | 30 +++++++++++++++------------- 1 file changed, 16 insertions(+), 14 deletions(-) diff --git a/cypress/generated/addon-docs.spec.ts b/cypress/generated/addon-docs.spec.ts index 0126bd9e2abd..0efffca5d2b5 100644 --- a/cypress/generated/addon-docs.spec.ts +++ b/cypress/generated/addon-docs.spec.ts @@ -16,21 +16,23 @@ describe('addon-docs', () => { }); skipOn('vue3', () => { - it('should provide source snippet', () => { - cy.getDocsElement() - .find('.docblock-code-toggle') - .first() - .should('contain.text', 'Show code') - // use force click so cypress does not automatically scroll, making the source block visible on this step - .click({ force: true }); + skipOn('html', () => { + it('should provide source snippet', () => { + cy.getDocsElement() + .find('.docblock-code-toggle') + .first() + .should('contain.text', 'Show code') + // use force click so cypress does not automatically scroll, making the source block visible on this step + .click({ force: true }); - cy.getDocsElement() - .find('pre.prismjs') - .first() - .should(($div) => { - const text = $div.text(); - expect(text).not.match(/^\(args\) => /); - }); + cy.getDocsElement() + .find('pre.prismjs') + .first() + .should(($div) => { + const text = $div.text(); + expect(text).not.match(/^\(args\) => /); + }); + }); }); }); }); From 0ca55ae561ca7524cfd458ff27034bce728a1a73 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ga=C3=ABtan=20Maisse?= Date: Thu, 11 Nov 2021 18:54:08 +0100 Subject: [PATCH 4/4] Add a repro config for Angular 12 and use it in E2E tests --- .circleci/config.yml | 5 +++-- lib/cli/src/repro-generators/configs.ts | 6 ++++++ 2 files changed, 9 insertions(+), 2 deletions(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index 831dcd0f48bc..c5222aac5d6a 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -195,7 +195,7 @@ jobs: command: yarn wait-on http://localhost:6000 - run: name: Run E2E tests - command: yarn test:e2e-framework --clean --all --skip angular11 --skip angular --skip vue3 --skip web_components_typescript --skip cra + command: yarn test:e2e-framework --clean --all --skip angular11 --skip angular --skip angular12 --skip vue3 --skip web_components_typescript --skip cra no_output_timeout: 5m - store_artifacts: path: /tmp/cypress-record @@ -221,7 +221,8 @@ jobs: name: Run E2E tests # Do not test CRA here because it's done in PnP part # TODO: Remove `web_components_typescript` as soon as Lit 2 stable is released - command: yarn test:e2e-framework vue3 angular angular11 web_components_typescript web_components_lit2 + # TODO: Add `angular` as soon as Storybook is compatible with Angular 13 + command: yarn test:e2e-framework vue3 angular12 angular11 web_components_typescript web_components_lit2 no_output_timeout: 5m - store_artifacts: path: /tmp/cypress-record diff --git a/lib/cli/src/repro-generators/configs.ts b/lib/cli/src/repro-generators/configs.ts index 20eab4bfea92..c3b2f6e79660 100644 --- a/lib/cli/src/repro-generators/configs.ts +++ b/lib/cli/src/repro-generators/configs.ts @@ -111,6 +111,12 @@ export const angular11: Parameters = { version: 'v11-lts', }; +export const angular12: Parameters = { + ...baseAngular, + name: 'angular12', + version: 'v12-lts', +}; + export const angular: Parameters = baseAngular; // #endregion