@salesforce/source-testkit 0.0.14 → 0.0.15
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +7 -0
- package/lib/testkit.js +3 -5
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -2,6 +2,13 @@
|
|
|
2
2
|
|
|
3
3
|
All notable changes to this project will be documented in this file. See [standard-version](https://github.com/conventional-changelog/standard-version) for commit guidelines.
|
|
4
4
|
|
|
5
|
+
### [0.0.15](https://github.com/salesforcecli/source-testkit/compare/v0.0.14...v0.0.15) (2021-09-29)
|
|
6
|
+
|
|
7
|
+
|
|
8
|
+
### Bug Fixes
|
|
9
|
+
|
|
10
|
+
* use appropriate config key based on executable ([cc36ff8](https://github.com/salesforcecli/source-testkit/commit/cc36ff859c4fc7e4645043cccbd39b75c0cc253c))
|
|
11
|
+
|
|
5
12
|
### [0.0.14](https://github.com/salesforcecli/source-testkit/compare/v0.0.13...v0.0.14) (2021-09-08)
|
|
6
13
|
|
|
7
14
|
|
package/lib/testkit.js
CHANGED
|
@@ -466,12 +466,10 @@ class SourceTestkit extends kit_1.AsyncCreatable {
|
|
|
466
466
|
});
|
|
467
467
|
}
|
|
468
468
|
async getDefaultUsername() {
|
|
469
|
-
const
|
|
469
|
+
const configVar = this.executableName === Executable.SF ? 'target-org' : core_1.Config.DEFAULT_USERNAME;
|
|
470
|
+
const configResult = cli_plugins_testkit_1.execCmd(`config:get ${configVar} --json`).jsonOutput;
|
|
470
471
|
const results = ts_types_1.get(configResult, 'result', configResult);
|
|
471
|
-
const username = results.find((r) => r.key ===
|
|
472
|
-
if (this.executableName === Executable.SF) {
|
|
473
|
-
cli_plugins_testkit_1.execCmd(`config:set target-org ${username} --json`);
|
|
474
|
-
}
|
|
472
|
+
const username = results.find((r) => r.key === configVar || r.name === configVar).value;
|
|
475
473
|
return username;
|
|
476
474
|
}
|
|
477
475
|
async createConnection() {
|
package/package.json
CHANGED