mirror of
https://github.com/langgenius/dify.git
synced 2026-05-06 02:18:08 +08:00
test: add unit tests for base components (#32818)
Co-authored-by: CodingOnStar <hanxujiang@dify.com>
This commit is contained in:
@ -1,7 +1,7 @@
|
||||
import { render, screen } from '@testing-library/react'
|
||||
import useTheme from '@/hooks/use-theme'
|
||||
import { Theme } from '@/types/app'
|
||||
import DifyLogo from './dify-logo'
|
||||
import DifyLogo from '../dify-logo'
|
||||
|
||||
vi.mock('@/hooks/use-theme', () => ({
|
||||
default: vi.fn(),
|
||||
@ -1,5 +1,5 @@
|
||||
import { render, screen } from '@testing-library/react'
|
||||
import LogoEmbeddedChatAvatar from './logo-embedded-chat-avatar'
|
||||
import LogoEmbeddedChatAvatar from '../logo-embedded-chat-avatar'
|
||||
|
||||
vi.mock('@/utils/var', () => ({
|
||||
basePath: '/test-base-path',
|
||||
@ -1,5 +1,5 @@
|
||||
import { render, screen } from '@testing-library/react'
|
||||
import LogoEmbeddedChatHeader from './logo-embedded-chat-header'
|
||||
import LogoEmbeddedChatHeader from '../logo-embedded-chat-header'
|
||||
|
||||
vi.mock('@/utils/var', () => ({
|
||||
basePath: '/test-base-path',
|
||||
@ -1,5 +1,5 @@
|
||||
import { render, screen } from '@testing-library/react'
|
||||
import LogoSite from './logo-site'
|
||||
import LogoSite from '../logo-site'
|
||||
|
||||
vi.mock('@/utils/var', () => ({
|
||||
basePath: '/test-base-path',
|
||||
Reference in New Issue
Block a user