diff --git a/.vitepress/components/FeaturesList.vue b/.vitepress/components/FeaturesList.vue index 11c24230..b440cc63 100644 --- a/.vitepress/components/FeaturesList.vue +++ b/.vitepress/components/FeaturesList.vue @@ -9,6 +9,7 @@ import ListItem from './ListItem.vue' Vite 通用的配置、转换器、解析器和插件。 +<<<<<<< HEAD 使用与你的应用相同的设置来运行测试! 智能文件监听模式,就像是测试的 HMR! 支持对 Vue、React、Svelte、Lit 等框架进行组件测试。 @@ -64,6 +65,17 @@ import ListItem from './ListItem.vue' 支持分片执行 报告未捕获的错误 +======= + Chai built-in for assertions + Jest expect compatible APIs + Jest-compatible mocking + happy-dom or jsdom for DOM mocking + Browser Mode for running component tests in the browser + Code coverage via v8 or istanbul + Rust-like in-source testing + Type Testing via expect-type + Sharding Support + Reporting Uncaught Errors +>>>>>>> 75b8e759c1128a8da6df977d50acf33d2c46d033 diff --git a/.vitepress/config.ts b/.vitepress/config.ts index 3b05b7ed..507100c4 100644 --- a/.vitepress/config.ts +++ b/.vitepress/config.ts @@ -51,7 +51,7 @@ export default ({ mode }: { mode: string }) => { ['link', { rel: 'icon', href: '/favicon.ico', sizes: '48x48' }], ['link', { rel: 'icon', href: '/logo-without-border.svg', type: 'image/svg+xml' }], ['meta', { name: 'author', content: `${teamMembers.map(c => c.name).join(', ')} and ${vitestName} contributors` }], - ['meta', { name: 'keywords', content: 'vitest, vite, test, coverage, snapshot, react, vue, preact, svelte, solid, lit, marko, ruby, cypress, puppeteer, jsdom, happy-dom, test-runner, jest, typescript, esm, tinyspy, node' }], + ['meta', { name: 'keywords', content: 'vitest, vite, test, coverage, snapshot, react, vue, preact, svelte, solid, lit, marko, ruby, cypress, puppeteer, jsdom, happy-dom, test-runner, jest, typescript, esm, node' }], ['meta', { property: 'og:title', content: vitestName }], ['meta', { property: 'og:description', content: vitestDescription }], ['meta', { property: 'og:url', content: ogUrl }], diff --git a/guide/features.md b/guide/features.md index 5d480c74..cfcc5b6f 100644 --- a/guide/features.md +++ b/guide/features.md @@ -120,7 +120,11 @@ it('renders correctly', () => { ## 对象模拟 (Mocking) {#mocking} +<<<<<<< HEAD 内置 [Tinyspy](https://github.com/tinylibs/tinyspy) 用于在 `vi` 对象上使用 `jest` 兼容的 API 进行对象模拟。 +======= +Vitest provides `jest`-compatible APIs on `vi` object. +>>>>>>> 75b8e759c1128a8da6df977d50acf33d2c46d033 ```ts import { expect, vi } from 'vitest'