import { vi } from 'vitest'
import { unref } from 'vue'

const uniMock = {
  canIUse: vi.fn(),
  getLocation: vi.fn(),
  getStorageSync: vi.fn(),
  getSystemInfoSync: vi.fn(() => ({ uniPlatform: 'mp-weixin' })),
  removeStorageSync: vi.fn(),
  setStorageSync: vi.fn(),
  setStorage: vi.fn(),
  showToast: vi.fn(),
}

vi.stubGlobal('uni', uniMock)
vi.stubGlobal('unref', unref)
