Skip to content

Commit

Permalink
Fix tests
Browse files Browse the repository at this point in the history
  • Loading branch information
karthiknadig committed Aug 29, 2023
1 parent 6d09733 commit a545e36
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -128,7 +128,9 @@ async function createCondaEnv(
dispose();
if (proc?.exitCode !== 0) {
traceError('Error while running venv creation script: ', progressAndTelemetry.getLastError());
deferred.reject(progressAndTelemetry.getLastError());
deferred.reject(
progressAndTelemetry.getLastError() || `Conda env creation failed with exitCode: ${proc?.exitCode}`,
);
} else {
deferred.resolve(condaEnvPath);
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -185,7 +185,8 @@ suite('Conda Creation provider tests', () => {
assert.isDefined(_error);
_error!('bad arguments');
_complete!();
await assert.isRejected(promise);
const result = await promise;
assert.ok(result?.error);
assert.isTrue(showErrorMessageWithLogsStub.calledOnce);
});

Expand Down Expand Up @@ -241,7 +242,8 @@ suite('Conda Creation provider tests', () => {

_next!({ out: `${CONDA_ENV_CREATED_MARKER}new_environment`, source: 'stdout' });
_complete!();
await assert.isRejected(promise);
const result = await promise;
assert.ok(result?.error);
assert.isTrue(showErrorMessageWithLogsStub.calledOnce);
});
});

0 comments on commit a545e36

Please sign in to comment.