Update mock imports
This commit is contained in:
parent
00e7cf6904
commit
6a9b672855
|
@ -10,7 +10,7 @@ import {
|
||||||
} from "./fixtures"
|
} from "./fixtures"
|
||||||
import { API } from "@/api"
|
import { API } from "@/api"
|
||||||
|
|
||||||
vi.mock("api", () => {
|
vi.mock("@/api", () => {
|
||||||
return {
|
return {
|
||||||
API: {
|
API: {
|
||||||
fetchAppRoutes: vi.fn(),
|
fetchAppRoutes: vi.fn(),
|
||||||
|
|
|
@ -28,7 +28,7 @@ import { makePropSafe as safe } from "@budibase/string-templates"
|
||||||
// Could move to fixtures
|
// Could move to fixtures
|
||||||
const COMP_PREFIX = "@budibase/standard-components"
|
const COMP_PREFIX = "@budibase/standard-components"
|
||||||
|
|
||||||
vi.mock("api", () => {
|
vi.mock("@/api", () => {
|
||||||
return {
|
return {
|
||||||
API: {
|
API: {
|
||||||
fetchComponentLibDefinitions: vi.fn(),
|
fetchComponentLibDefinitions: vi.fn(),
|
||||||
|
|
|
@ -7,7 +7,7 @@ import {
|
||||||
} from "@/stores/builder/navigation"
|
} from "@/stores/builder/navigation"
|
||||||
import { appStore } from "@/stores/builder"
|
import { appStore } from "@/stores/builder"
|
||||||
|
|
||||||
vi.mock("api", () => {
|
vi.mock("@/api", () => {
|
||||||
return {
|
return {
|
||||||
API: {
|
API: {
|
||||||
saveAppMetadata: vi.fn(),
|
saveAppMetadata: vi.fn(),
|
||||||
|
|
|
@ -57,7 +57,7 @@ vi.mock("@/stores/builder/components/utils", () => {
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
|
|
||||||
vi.mock("api", () => {
|
vi.mock("@/api", () => {
|
||||||
return {
|
return {
|
||||||
API: {
|
API: {
|
||||||
fetchAppPackage: vi.fn(),
|
fetchAppPackage: vi.fn(),
|
||||||
|
|
|
@ -20,7 +20,7 @@ vi.mock("svelte/store", () => {
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
|
|
||||||
vi.mock("api", () => {
|
vi.mock("@/api", () => {
|
||||||
return {
|
return {
|
||||||
API: {
|
API: {
|
||||||
getEnvironment: vi.fn(),
|
getEnvironment: vi.fn(),
|
||||||
|
|
|
@ -1,6 +1,5 @@
|
||||||
import { it, expect, describe, beforeEach, vi } from "vitest"
|
import { it, expect, describe, beforeEach, vi } from "vitest"
|
||||||
import { createBackupsStore } from "./backups"
|
import { createBackupsStore } from "./backups"
|
||||||
|
|
||||||
import { writable } from "svelte/store"
|
import { writable } from "svelte/store"
|
||||||
import { API } from "@/api"
|
import { API } from "@/api"
|
||||||
|
|
||||||
|
@ -16,7 +15,7 @@ vi.mock("svelte/store", () => {
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
|
|
||||||
vi.mock("api", () => {
|
vi.mock("@/api", () => {
|
||||||
return {
|
return {
|
||||||
API: {
|
API: {
|
||||||
searchBackups: vi.fn(() => "searchBackupsReturn"),
|
searchBackups: vi.fn(() => "searchBackupsReturn"),
|
||||||
|
|
Loading…
Reference in New Issue