rusackas commented on code in PR #41636: URL: https://github.com/apache/superset/pull/41636#discussion_r3562092658
########## superset-frontend/playwright/tests/home/welcome.spec.ts: ########## @@ -0,0 +1,36 @@ +/** + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + */ +import { test, expect } from '@playwright/test'; +import { URL } from '../../utils/urls'; +import { TIMEOUT } from '../../utils/constants'; + +// Smoke test guarding against a blank Home/welcome landing page (e.g. a shell +// or route-layout regression that renders only the top navigation). The auth +// suite only waits for the welcome URL + session cookie, so it would not catch +// a welcome page that redirects correctly but renders no content. +test('welcome page renders its content, not just the nav', async ({ page }) => { + await page.goto(`/${URL.WELCOME}`); + + // "Recents" is a Home content section header (a Collapse panel) that does not + // exist in the top navigation, so its presence proves the route content + // rendered — not just the app shell. + await expect(page.getByText('Recents', { exact: true })).toBeVisible({ Review Comment: This is a Playwright E2E test, not a jest unit test, so it hits the real app in the default locale rather than mocked i18n. Other specs in this suite do the same (hardcoded English strings), so leaving it as-is. ########## superset-frontend/jest.config.js: ########## @@ -75,7 +75,7 @@ module.exports = { // @ant-design/colors and @ant-design/fast-color are allowed through because // @ant-design/icons >= 6.3 deep-imports the ESM build of @ant-design/colors // from its CJS output, so babel-jest must transform those files. - 'node_modules/(?!@ant-design/(colors|fast-color)|@formatjs/.*|d3-(array|interpolate|color|time|scale|time-format|format)|internmap|@mapbox/tiny-sdf|remark-gfm|(?!@ngrx|(?!deck.gl)|d3-scale)|markdown-table|micromark-*.|decode-named-character-reference|character-entities|mdast-util-*.|unist-util-*.|ccount|escape-string-regexp|nanoid|uuid|@rjsf/*.|echarts|zrender|fetch-mock|pretty-ms|parse-ms|ol|@babel/runtime|@emotion|cheerio|cheerio/lib|parse5|dom-serializer|entities|htmlparser2|rehype-sanitize|hast-util-sanitize|unified|unist-.*|hast-.*|rehype-.*|remark-.*|mdast-.*|micromark-.*|parse-entities|property-information|space-separated-tokens|comma-separated-tokens|bail|devlop|zwitch|longest-streak|geostyler|geostyler-.*|(?!geostyler)lodash|react-error-boundary|react-json-tree|react-base16-styling|lodash-es|rbush|quickselect|react-diff-viewer-continued|storybook/*.|json-stringify-pretty-compact)', + 'node_modules/(?!@ant-design/(colors|fast-color)|@formatjs/.*|d3-(array|interpolate|color|time|scale|time-format|format)|internmap|@mapbox/tiny-sdf|remark-gfm|(?!@ngrx|(?!deck.gl)|d3-scale)|markdown-table|micromark-*.|decode-named-character-reference|character-entities|mdast-util-*.|unist-util-*.|ccount|escape-string-regexp|nanoid|uuid|@rjsf/*.|@x0k/.*|echarts|zrender|fetch-mock|pretty-ms|parse-ms|ol|@babel/runtime|@emotion|cheerio|cheerio/lib|parse5|dom-serializer|entities|htmlparser2|rehype-sanitize|hast-util-sanitize|unified|unist-.*|hast-.*|rehype-.*|remark-.*|mdast-.*|micromark-.*|parse-entities|property-information|space-separated-tokens|comma-separated-tokens|bail|devlop|zwitch|longest-streak|geostyler|geostyler-.*|(?!geostyler)lodash|react-error-boundary|react-json-tree|react-base16-styling|lodash-es|rbush|quickselect|react-diff-viewer-continued|storybook/*.|json-stringify-pretty-compact)', Review Comment: @x0k/json-schema-merge isn't dead, it's a transitive dep of @rjsf/utils (which ScheduleQueryButton imports), so it still needs the jest transform. -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected] --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
