You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@superset.apache.org by ma...@apache.org on 2025/03/26 02:57:03 UTC
(superset) 10/11: fix test
This is an automated email from the ASF dual-hosted git repository.
maximebeauchemin pushed a commit to branch template_less
in repository https://gitbox.apache.org/repos/asf/superset.git
commit 58724b1c5c199ced3c7358a55d39a323e3c980e4
Author: Maxime Beauchemin <ma...@gmail.com>
AuthorDate: Tue Mar 25 19:39:38 2025 -0700
fix test
---
.../ErrorMessage/ErrorMessageWithStackTrace.test.tsx | 15 ++++++++-------
1 file changed, 8 insertions(+), 7 deletions(-)
diff --git a/superset-frontend/src/components/ErrorMessage/ErrorMessageWithStackTrace.test.tsx b/superset-frontend/src/components/ErrorMessage/ErrorMessageWithStackTrace.test.tsx
index ecb8a79c3b..3cb8b9294c 100644
--- a/superset-frontend/src/components/ErrorMessage/ErrorMessageWithStackTrace.test.tsx
+++ b/superset-frontend/src/components/ErrorMessage/ErrorMessageWithStackTrace.test.tsx
@@ -22,13 +22,14 @@ import { render, screen, userEvent } from 'spec/helpers/testing-library';
import ErrorMessageWithStackTrace from './ErrorMessageWithStackTrace';
import BasicErrorAlert from './BasicErrorAlert';
-jest.mock(
- 'src/components/Icons/Icon',
- () =>
- ({ fileName }: { fileName: string }) => (
- <span role="img" aria-label={fileName.replace('_', '-')} />
- ),
-);
+jest.mock('src/components/Icons', () => ({
+ ErrorSolid: ({ iconColor }: { iconColor: string }) => (
+ <span role="img" aria-label="error-solid" style={{ color: iconColor }} />
+ ),
+ WarningSolid: ({ iconColor }: { iconColor: string }) => (
+ <span role="img" aria-label="warning-solid" style={{ color: iconColor }} />
+ ),
+}));
const mockedProps = {
level: 'warning' as ErrorLevel,