Skip to content

Commit

Permalink
Merge branch 'main' into feat/rename-insight-find
Browse files Browse the repository at this point in the history
  • Loading branch information
yuyutaotao committed Jul 25, 2024
2 parents d04d170 + 3444a7d commit 81cdd1d
Show file tree
Hide file tree
Showing 30 changed files with 8 additions and 6 deletions.
1 change: 1 addition & 0 deletions packages/midscene/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -61,6 +61,7 @@
"new": "modern new",
"upgrade": "modern upgrade",
"test": "vitest --run",
"test:all": "AITEST=true vitest --run",
"prepublishOnly": "npm run build"
},
"dependencies": {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
},
],
"error": [],
"prompt": "Switch language(包括中文、english内容)",
"prompt": "Switch language(include:中文、english text)",
},
{
"elements": [
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,7 @@ export async function runTestCases(


export const repeat = (times: number, fn: (index: number) => void) => {
for (let i = 0; i < times; i++) {
for (let i = 1; i <= times; i++) {
fn(i);
}
};
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ const testCases = [
multi: false,
},
{
description: 'Switch language(包括中文、english内容)',
description: 'Switch language(include:中文、english text)',
multi: false,
},
{
Expand Down
File renamed without changes.
File renamed without changes.
5 changes: 3 additions & 2 deletions packages/midscene/vitest.config.ts
Original file line number Diff line number Diff line change
@@ -1,8 +1,9 @@
import { defineConfig } from 'vitest/config';
import path from 'path';

const disableAiTest = true;
const aiModelTest = disableAiTest? ['tests/inspector/*.test.ts', 'tests/openai.test.ts', 'tests/showcase.test.ts']: [];
const enableTest = process.env.AITEST;

const aiModelTest = enableTest !== 'true' ? ['tests/ai-model/**/*.test.ts']: [];

export default defineConfig({
test: {
Expand Down
2 changes: 1 addition & 1 deletion packages/web-integration/tests/e2e/tool.ts
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ export async function generateTestData(page: PlaywrightPage, targetDir: string,
export function generateTestDataPath(testDataName: string) {
// `dist/lib/index.js` Is the default export path
const modulePath = require.resolve('@midscene/core').replace('dist/lib/index.js', '');
const midsceneTestDataPath = path.join(modulePath, `tests/inspector/test-data/${testDataName}`);
const midsceneTestDataPath = path.join(modulePath, `tests/ai-model/inspector/test-data/${testDataName}`);

return midsceneTestDataPath;
}
Expand Down

0 comments on commit 81cdd1d

Please sign in to comment.