Skip to content

Commit

Permalink
unscoped tests
Browse files Browse the repository at this point in the history
  • Loading branch information
eric2788 committed Oct 24, 2024
1 parent 35a32dc commit 6aff1a4
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 10 deletions.
2 changes: 1 addition & 1 deletion tests/features/jimaku.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -125,7 +125,7 @@ test('測試彈出同傳視窗', async ({ room, context, optionPageUrl, page, co
await expect(checkbox).not.toBeChecked()
})

test('测试同传字幕AI总结', { tag: "@scoped" }, async ({ room, content: p, context, optionPageUrl, page }) => {
test('测试同传字幕AI总结', async ({ room, content: p, context, optionPageUrl, page }) => {

test.slow()
logger.info('正在修改設定...')
Expand Down
10 changes: 5 additions & 5 deletions tests/integrations/summarizer.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -62,13 +62,13 @@ function testModel(model: string, { trash = false, provider = 'worker' }: { tras

test.slow()

test('测试 @cf/qwen/qwen1.5-14b-chat-awq 模型的AI总结结果', { tag: "@scoped" }, testModel('@cf/qwen/qwen1.5-14b-chat-awq'))
test('测试 @cf/qwen/qwen1.5-14b-chat-awq 模型的AI总结结果', testModel('@cf/qwen/qwen1.5-14b-chat-awq'))

test('测试 @cf/qwen/qwen1.5-7b-chat-awq 模型的AI总结结果', { tag: "@scoped" }, testModel('@cf/qwen/qwen1.5-7b-chat-awq'))
test('测试 @cf/qwen/qwen1.5-7b-chat-awq 模型的AI总结结果', testModel('@cf/qwen/qwen1.5-7b-chat-awq'))

test('测试 @cf/qwen/qwen1.5-1.8b-chat 模型的AI总结结果', { tag: "@scoped" }, testModel('@cf/qwen/qwen1.5-1.8b-chat'))
test('测试 @cf/qwen/qwen1.5-1.8b-chat 模型的AI总结结果', testModel('@cf/qwen/qwen1.5-1.8b-chat'))

// this model is too trash that cannot have any keywords
test('测试 @hf/google/gemma-7b-it 模型的AI总结结果', { tag: "@scoped" }, testModel('@hf/google/gemma-7b-it', { trash: true }))
test('测试 @hf/google/gemma-7b-it 模型的AI总结结果', testModel('@hf/google/gemma-7b-it', { trash: true }))

test('测试 @hf/nousresearch/hermes-2-pro-mistral-7b 模型的AI总结结果', { tag: "@scoped" }, testModel('@hf/nousresearch/hermes-2-pro-mistral-7b'))
test('测试 @hf/nousresearch/hermes-2-pro-mistral-7b 模型的AI总结结果', testModel('@hf/nousresearch/hermes-2-pro-mistral-7b'))
8 changes: 4 additions & 4 deletions tests/units/llm.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ import createLLMProvider from "~llms"

test.slow()

test('嘗試使用 Cloudflare AI 對話', { tag: "@scoped" }, async () => {
test('嘗試使用 Cloudflare AI 對話', async () => {

test.skip(!process.env.CF_ACCOUNT_ID || !process.env.CF_API_TOKEN, '請設定 CF_ACCOUNT_ID 和 CF_API_TOKEN 環境變數')

Expand Down Expand Up @@ -35,7 +35,7 @@ test('嘗試使用 Cloudflare AI 對話', { tag: "@scoped" }, async () => {
expect(msg).not.toBe('')
})

test('嘗試使用 Gemini Nano 對話', { tag: "@scoped" }, async ({ page, modules }) => {
test('嘗試使用 Gemini Nano 對話', async ({ page, modules }) => {

const supported = await page.evaluate(async () => {
return !!window.ai;
Expand Down Expand Up @@ -72,7 +72,7 @@ test('嘗試使用 Gemini Nano 對話', { tag: "@scoped" }, async ({ page, modul
logger.info('stream response: ', ret2)
})

test('嘗試使用 Remote Worker 對話', { tag: "@scoped" }, async () => {
test('嘗試使用 Remote Worker 對話', async () => {

const llm = createLLMProvider({ provider: 'worker' })

Expand All @@ -97,7 +97,7 @@ test('嘗試使用 Remote Worker 對話', { tag: "@scoped" }, async () => {

})

test('嘗試使用 Web LLM 對話', { tag: "@scoped" }, async ({ modules, page }) => {
test('嘗試使用 Web LLM 對話', async ({ modules, page }) => {

test.setTimeout(0)
await modules['llm'].loadToPage()
Expand Down

0 comments on commit 6aff1a4

Please sign in to comment.