-
Notifications
You must be signed in to change notification settings - Fork 124
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix(newman-reporter-allure): fix reporter error in case of empty exec (…
- Loading branch information
Showing
17 changed files
with
187 additions
and
82 deletions.
There are no files selected for viewing
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
Binary file renamed
BIN
+6.95 KB
...agent-npm-0.6.3-0942abdb9d-71ea42fa77.zip → ...agent-npm-0.6.4-934a48e21a-fcfbd7c61d.zip
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file renamed
BIN
+79.5 KB
...ewman-npm-6.1.2-33b0e0fda8-850f551bb2.zip → ...ewman-npm-6.2.1-1ced31ce67-b52282ace5.zip
Binary file not shown.
Binary file removed
BIN
-75.3 KB
.yarn/cache/postman-request-npm-2.88.1-postman.33-2d5f78ca19-fd747e6e48.zip
Binary file not shown.
Binary file added
BIN
+56.2 KB
.yarn/cache/postman-request-npm-2.88.1-postman.34-48f248fd5f-69a739ef63.zip
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,80 @@ | ||
/* eslint-disable @stylistic/quotes */ | ||
import { afterAll, afterEach, beforeAll, expect, test } from "vitest"; | ||
import { server } from "../mocks/server.js"; | ||
import { runNewmanCollection } from "../utils.js"; | ||
|
||
beforeAll(() => server.listen()); | ||
afterEach(() => server.resetHandlers()); | ||
afterAll(() => server.close()); | ||
|
||
test("empty exec", async () => { | ||
const { tests } = await runNewmanCollection({ | ||
item: [ | ||
{ | ||
name: "Header Test Request", | ||
event: [ | ||
{ | ||
listen: "test", | ||
script: { | ||
exec: [""], | ||
type: "text/javascript", | ||
}, | ||
}, | ||
{ | ||
listen: "prerequest", | ||
script: { | ||
exec: [""], | ||
type: "text/javascript", | ||
}, | ||
}, | ||
], | ||
request: { | ||
method: "GET", | ||
header: [ | ||
{ | ||
key: "A-Header", | ||
value: "with some value", | ||
}, | ||
{ | ||
key: "B-Header", | ||
value: "with other value", | ||
}, | ||
], | ||
body: { | ||
mode: "raw", | ||
raw: '{\r\n testVal1: "body",\r\n testVal2: 1,\r\n testVal3: true,\r\n}', | ||
}, | ||
url: { | ||
host: ["example", "com"], | ||
path: ["headers"], | ||
}, | ||
}, | ||
response: [], | ||
}, | ||
], | ||
}); | ||
|
||
expect(tests).toHaveLength(1); | ||
expect(tests[0].attachments).toEqual([ | ||
{ | ||
name: "Request Headers", | ||
source: expect.stringContaining("attachment.json"), | ||
type: "application/json", | ||
}, | ||
{ | ||
name: "Request Body", | ||
source: expect.stringContaining("attachment.txt"), | ||
type: "text/plain", | ||
}, | ||
{ | ||
name: "Response Headers", | ||
source: expect.stringContaining("attachment.json"), | ||
type: "application/json", | ||
}, | ||
{ | ||
name: "Response Body", | ||
source: expect.stringContaining("attachment.txt"), | ||
type: "text/plain", | ||
}, | ||
]); | ||
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.