test(clone-modal): add smoke test for InputView
This commit is contained in:
@@ -0,0 +1,28 @@
|
||||
import { describe, expect, it, vi } from "vitest"
|
||||
import { render } from "@testing-library/react"
|
||||
import InputView from "@/components/voice/clone-modal/InputView"
|
||||
|
||||
vi.mock("@ant-design/icons", () => ({
|
||||
AudioOutlined: () => null,
|
||||
UploadOutlined: () => null,
|
||||
CheckOutlined: () => null,
|
||||
CloseOutlined: () => null,
|
||||
PlayCircleOutlined: () => null,
|
||||
PauseCircleOutlined: () => null,
|
||||
DeleteOutlined: () => null,
|
||||
InfoCircleOutlined: () => null,
|
||||
}))
|
||||
|
||||
vi.mock("antd", () => ({
|
||||
Button: ({ children }: any) => null,
|
||||
Input: () => null,
|
||||
Progress: () => null,
|
||||
message: { success: vi.fn(), error: vi.fn(), warning: vi.fn() },
|
||||
}))
|
||||
|
||||
describe("InputView", () => {
|
||||
it("renders without crashing", () => {
|
||||
const { container } = render(<InputView />)
|
||||
expect(container).toBeTruthy()
|
||||
})
|
||||
})
|
||||
Reference in New Issue
Block a user