feat: 管理后台接真实接口并加 Playwright e2e

This commit is contained in:
Nixevol
2026-09-30 09:20:01 +08:00
parent a22912d95a
commit b75b67928b
24 changed files with 1299 additions and 71 deletions
+3 -1
View File
@@ -1,6 +1,6 @@
import { config, mount, flushPromises } from "@vue/test-utils";
import { createPinia, setActivePinia } from "pinia";
import { beforeEach, describe, expect, it } from "vitest";
import { beforeEach, describe, expect, it, vi } from "vitest";
import {
NConfigProvider,
NDialogProvider,
@@ -12,6 +12,8 @@ import { defineComponent, h, nextTick } from "vue";
import EndpointsView from "./EndpointsView.vue";
import { mockApi } from "@/api/mock";
vi.mock("@/api/admin", async () => import("@/api/admin-mock"));
config.global.stubs = { teleport: true };
function wrap(Comp: object) {