feat(cli): Enhance test discovery with support for single file and glob pattern execution using improved CLI argument detection

This commit is contained in:
2025-05-15 14:37:55 +00:00
parent 1f73751a8c
commit a57edeef64
11 changed files with 1660 additions and 1252 deletions

View File

@@ -7,9 +7,11 @@ import { coloredString as cs } from '@push.rocks/consolecolor';
import { TestDirectory } from './tstest.classes.testdirectory.js';
import { TapCombinator } from './tstest.classes.tap.combinator.js';
import { TapParser } from './tstest.classes.tap.parser.js';
import { TestExecutionMode } from './index.js';
export class TsTest {
public testDir: TestDirectory;
public executionMode: TestExecutionMode;
public smartshellInstance = new plugins.smartshell.Smartshell({
executor: 'bash',
@@ -20,8 +22,9 @@ export class TsTest {
public tsbundleInstance = new plugins.tsbundle.TsBundle();
constructor(cwdArg: string, relativePathToTestDirectory: string) {
this.testDir = new TestDirectory(cwdArg, relativePathToTestDirectory);
constructor(cwdArg: string, testPathArg: string, executionModeArg: TestExecutionMode) {
this.executionMode = executionModeArg;
this.testDir = new TestDirectory(cwdArg, testPathArg, executionModeArg);
}
async run() {