Merge remote-tracking branch 'upstream/main' into bug/correct-result-reporting

This commit is contained in:
Thomas Pyle
2023-10-03 22:15:53 -04:00
72 changed files with 1351 additions and 197 deletions

View File

@@ -20,7 +20,7 @@ const run = async () => {
.commandDir('commands')
.epilogue(CLI_EPILOGUE)
.usage('Usage: $0 <command> [options]')
.demandCommand(1, "Woof !! Let's play with some apis !!")
.demandCommand(1, "Woof !! Let's play with some APIs !!")
.help('h')
.alias('h', 'help');
};

View File

@@ -187,7 +187,7 @@ const runSingleRequest = async function (
// run assertions
let assertionResults = [];
const assertions = get(bruJson, 'request.assertions');
if (assertions && assertions.length) {
if (assertions) {
const assertRuntime = new AssertRuntime();
assertionResults = assertRuntime.runAssertions(
assertions,
@@ -211,7 +211,7 @@ const runSingleRequest = async function (
// run tests
let testResults = [];
const testFile = get(bruJson, 'request.tests');
if (testFile && testFile.length) {
if (typeof testFile === 'string') {
const testRuntime = new TestRuntime();
const result = await testRuntime.runTests(
testFile,