Skip to content

Commit

Permalink
More test fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
cb1kenobi committed Sep 20, 2023
1 parent 07568cf commit 7309003
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 4 deletions.
11 changes: 8 additions & 3 deletions test/commands/ti-sdk.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@ describe('ti sdk', { concurrency: true }, () => {
const sdkPath = join(tmpSDKDir, 'mobilesdk', 'win32', '12.2.0.GA');

// list sdks (no sdks installed)
let { exitCode, stdout } = await run(['sdk']); // no `ls` to test default subcommand
let { exitCode, stdout, stderr } = await run(['sdk']); // no `ls` to test default subcommand
let output = stripColor(stdout);
assert.match(output, /Titanium Command-Line Interface/);
assert.match(output, new RegExp(`SDK Install Locations:\n\\s*${tmpSDKDir.replace(/\\/g, '\\\\')}`));
Expand All @@ -91,8 +91,13 @@ describe('ti sdk', { concurrency: true }, () => {
assert.strictEqual(exitCode, 0);

// install an sdk
({ exitCode, stdout } = await run(['sdk', 'install', '12.2.0.GA', '--no-progress-bars']));
assert.match(stdout, /successfully installed/);
({ exitCode, stdout, stderr } = await run(['sdk', 'install', '12.2.0.GA', '--no-progress-bars']));
try {
assert.match(stdout, /successfully installed/);
} catch (e) {
console.log(stderr);
throw e;
}
assert.strictEqual(exitCode, 0);

// list sdks
Expand Down
2 changes: 1 addition & 1 deletion test/util/timodule.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ describe('timodule', () => {
});

it('should find modules in a search path', async () => {
const tmpModulesDir = tmpDirName();
const tmpModulesDir = join(tmpDirName(), 'modules');
try {
await fs.copy(join(fixturesDir, 'modules'), tmpModulesDir);

Expand Down

0 comments on commit 7309003

Please sign in to comment.