mirror of
https://github.com/web-infra-dev/midscene.git
synced 2025-07-05 16:10:56 +00:00

* feat(web-integration): add support for new agent method(aiBoolean, aiString, aiNumber, aiLocate) * fix(core, web-integration): update data extraction logic and refine return types for agent methods * feat(site): add detailed descriptions and examples * fix(web-integration): remove unused properties from aiLocate return type and update UI titles * fix(core): enhance agent methods for better extraction and querying * fix(core): update test scripts and refine data extraction prompts * fix(core): refine return type in ExecutionTaskApply and remove unused import in inspect * fix(core): update data extraction logic and enhance type handling in Insight class * fix(web-integration): update import path for puppeteerAgentForTarget in player test file * fix(core): tests fix * fix(core): fix tests * fix(shared): enhance imageInfo tests by validating individual properties and updating snapshots * fix(site): remove waitForNavigationTimeout from Playwright integration examples * fix(site): update timeout configuration examples in FAQ for clarity * test(web-integration): remove unused client-extractor test and related snapshots * chore(core): fix query implementation * fix(report): improve data handling in DetailSide component and enhance output display * fix(core): refine data extraction prompts and improve error handling in PageTaskExecutor * fix(core): update data extraction prompt for clarity and type validation --------- Co-authored-by: yutao <yutao.tao@bytedance.com>
16 lines
426 B
TypeScript
16 lines
426 B
TypeScript
import { describe, expect, it } from 'vitest';
|
|
import { getRunningPkgInfo } from '../../src/node/fs';
|
|
|
|
describe('fs', () => {
|
|
it('getRunningPkgInfo', () => {
|
|
const info = getRunningPkgInfo();
|
|
expect(info).toBeDefined();
|
|
expect(info?.dir).toMatch(/shared$/);
|
|
});
|
|
|
|
it('getRunningPkgInfo - no package.json', () => {
|
|
const info = getRunningPkgInfo('/home');
|
|
expect(info?.dir).toEqual('/home');
|
|
});
|
|
});
|