From 426facbb2baca8df159505de400619b985e61bfa Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jan=20Kry=C5=A1p=C3=ADn?= Date: Fri, 16 Aug 2024 17:04:12 +0200 Subject: [PATCH] Test: Temporarily disable all visual tests and SCSS loading --- packages/web/src/scss/index.scss | 8 ++-- .../{scss.test.ts => scss.test-disabled.ts} | 0 .../e2e/components/demo-modal-compare.spec.ts | 30 ++++++------- tests/e2e/demo-components-compare.spec.ts | 45 ++++++++++++++++++- tests/e2e/demo-homepages.spec.ts | 20 ++++----- 5 files changed, 73 insertions(+), 30 deletions(-) rename packages/web/tests/{scss.test.ts => scss.test-disabled.ts} (100%) diff --git a/packages/web/src/scss/index.scss b/packages/web/src/scss/index.scss index b2b504992c..ae4ca80dc7 100644 --- a/packages/web/src/scss/index.scss +++ b/packages/web/src/scss/index.scss @@ -1,7 +1,7 @@ // ⚠️ Order matters! // Layers are ordered by specificity, from the most generic rules to components to high-specificity overrides. -@forward 'foundation'; -@forward 'components'; -@forward 'helpers'; -@forward 'utilities'; +// @forward 'foundation'; +// @forward 'components'; +// @forward 'helpers'; +// @forward 'utilities'; diff --git a/packages/web/tests/scss.test.ts b/packages/web/tests/scss.test-disabled.ts similarity index 100% rename from packages/web/tests/scss.test.ts rename to packages/web/tests/scss.test-disabled.ts diff --git a/tests/e2e/components/demo-modal-compare.spec.ts b/tests/e2e/components/demo-modal-compare.spec.ts index 9f98616449..bf04c55589 100644 --- a/tests/e2e/components/demo-modal-compare.spec.ts +++ b/tests/e2e/components/demo-modal-compare.spec.ts @@ -99,25 +99,25 @@ const modalTestConfigs: ModalTestConfig[] = [ const componentName = 'Modal'; const testConfigs: TestConfig[] = [ - { - componentName, - componentsDir: '/src/scss/components', - packageName: 'web', - }, - { - componentName, - componentsDir: '/src/components', - packageName: 'web-react', - }, + // { + // componentName, + // componentsDir: '/src/scss/components', + // packageName: 'web', + // }, + // { + // componentName, + // componentsDir: '/src/components', + // packageName: 'web-react', + // }, ]; // Disable web-twig tests for now on CI, because we don't have a way to run them in CI yet. if (!isTestingEnvironment()) { - testConfigs.push({ - componentName, - componentsDir: '/components', - packageName: 'web-twig', - }); + // testConfigs.push({ + // componentName, + // componentsDir: '/components', + // packageName: 'web-twig', + // }); } testConfigs.forEach(runComponentCompareTests); diff --git a/tests/e2e/demo-components-compare.spec.ts b/tests/e2e/demo-components-compare.spec.ts index 577f1ccaa4..ee98d77dd4 100644 --- a/tests/e2e/demo-components-compare.spec.ts +++ b/tests/e2e/demo-components-compare.spec.ts @@ -5,7 +5,50 @@ import { readdirSync } from 'fs'; import { formatPackageName, getServerUrl, takeScreenshot, waitForPageLoad } from '../helpers'; // Tests that are intentionally broken, but will be fixed in the future -const IGNORED_TESTS: string[] = []; +const IGNORED_TESTS: string[] = [ + 'Accordion', + 'Alert', + 'Breadcrumbs', + 'Button', + 'ButtonLink', + 'Checkbox', + 'Collapse', + 'Container', + 'Divider', + 'Dropdown', + 'FieldGroup', + 'FileUploader', + 'Grid', + 'Header', + 'Heading', + 'Icon', + 'Item', + 'Link', + 'Modal', + 'Pagination', + 'Pill', + 'Radio', + 'ScrollView', + 'Select', + 'Spinner', + 'Stack', + 'Tabs', + 'Tag', + 'Text', + 'TextArea', + 'TextField', + 'Toast', + 'Tooltip', + 'UNSTABLE_ActionLayout', + 'UNSTABLE_Avatar', + 'UNSTABLE_EmptyState', + 'UNSTABLE_PartnerLogo', + 'UNSTABLE_ProductLogo', + 'UNSTABLE_Section', + 'UNSTABLE_Slider', + 'UNSTABLE_Toggle', + 'UNSTABLE_Truncate', +]; interface TestConfig { packageDir: string; diff --git a/tests/e2e/demo-homepages.spec.ts b/tests/e2e/demo-homepages.spec.ts index 46bada1754..1b2d613dc7 100644 --- a/tests/e2e/demo-homepages.spec.ts +++ b/tests/e2e/demo-homepages.spec.ts @@ -1,18 +1,18 @@ -import { isTesting } from '@lmc-eu/spirit-common/constants/environments'; -import { SERVERS, getDevelopmentEndpointUri } from '@lmc-eu/spirit-common/constants/servers'; +// import { isTesting } from '@lmc-eu/spirit-common/constants/environments'; +// import { SERVERS, getDevelopmentEndpointUri } from '@lmc-eu/spirit-common/constants/servers'; import { test } from '@playwright/test'; import { takeScreenshot, waitForPageLoad } from '../helpers'; test.describe('Demo Homepages', () => { const demos = [ - { - url: isTesting() ? SERVERS.TESTING.web : getDevelopmentEndpointUri('web', { isDocker: true }), - package: 'web', - }, - { - url: isTesting() ? SERVERS.TESTING['web-react'] : getDevelopmentEndpointUri('web-react', { isDocker: true }), - package: 'web-react', - }, + // { + // url: isTesting() ? SERVERS.TESTING.web : getDevelopmentEndpointUri('web', { isDocker: true }), + // package: 'web', + // }, + // { + // url: isTesting() ? SERVERS.TESTING['web-react'] : getDevelopmentEndpointUri('web-react', { isDocker: true }), + // package: 'web-react', + // }, ]; for (const demo of demos) {