doc-detective 2.11.0 → 2.11.2
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/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "doc-detective",
|
|
3
|
-
"version": "2.11.
|
|
3
|
+
"version": "2.11.2",
|
|
4
4
|
"description": "Treat doc content as testable assertions to validate doc accuracy and product UX.",
|
|
5
5
|
"bin": {
|
|
6
6
|
"doc-detective": "src/index.js"
|
|
@@ -32,12 +32,12 @@
|
|
|
32
32
|
"homepage": "https://github.com/doc-detective/doc-detective#readme",
|
|
33
33
|
"dependencies": {
|
|
34
34
|
"doc-detective-common": "^1.15.0",
|
|
35
|
-
"doc-detective-core": "^2.11.
|
|
35
|
+
"doc-detective-core": "^2.11.2",
|
|
36
36
|
"prompt-sync": "^4.2.0",
|
|
37
37
|
"yargs": "^17.7.2"
|
|
38
38
|
},
|
|
39
39
|
"devDependencies": {
|
|
40
40
|
"chai": "^4.3.10",
|
|
41
|
-
"mocha": "^10.
|
|
41
|
+
"mocha": "^10.4.0"
|
|
42
42
|
}
|
|
43
43
|
}
|
|
@@ -0,0 +1,55 @@
|
|
|
1
|
+
{
|
|
2
|
+
"id": "http tests",
|
|
3
|
+
"description": "This is a test collection",
|
|
4
|
+
"tests": [
|
|
5
|
+
{
|
|
6
|
+
"id": "env variables test",
|
|
7
|
+
"description": "These tests will show off how using env files to set variables works in Doc Detective.",
|
|
8
|
+
"steps": [
|
|
9
|
+
{
|
|
10
|
+
"action": "setVariables",
|
|
11
|
+
"path": "test/artifacts/env"
|
|
12
|
+
},
|
|
13
|
+
{
|
|
14
|
+
"action": "httpRequest",
|
|
15
|
+
"url": "https://reqres.in/api/users",
|
|
16
|
+
"method": "post",
|
|
17
|
+
"requestData": {
|
|
18
|
+
"auth": "$SECRET",
|
|
19
|
+
"name": "$USER",
|
|
20
|
+
"job": "$JOB"
|
|
21
|
+
},
|
|
22
|
+
"responseData": {
|
|
23
|
+
"name": "John Doe",
|
|
24
|
+
"job": "Software Engineer"
|
|
25
|
+
},
|
|
26
|
+
"statusCodes": [200, 201]
|
|
27
|
+
},
|
|
28
|
+
{
|
|
29
|
+
"action": "httpRequest",
|
|
30
|
+
"url": "https://reqres.in/api/users",
|
|
31
|
+
"method": "get",
|
|
32
|
+
"envsFromResponseData": [
|
|
33
|
+
{
|
|
34
|
+
"name": "ID",
|
|
35
|
+
"jqFilter": ".data[0].id"
|
|
36
|
+
}
|
|
37
|
+
],
|
|
38
|
+
"statusCodes": [200, 201]
|
|
39
|
+
},
|
|
40
|
+
{
|
|
41
|
+
"action": "httpRequest",
|
|
42
|
+
"url": "https://reqres.in/api/users/$ID",
|
|
43
|
+
"method": "get",
|
|
44
|
+
"responseData": {
|
|
45
|
+
"data": {
|
|
46
|
+
"first_name": "George",
|
|
47
|
+
"last_name": "Bluth"
|
|
48
|
+
}
|
|
49
|
+
},
|
|
50
|
+
"statusCodes": [200, 201]
|
|
51
|
+
}
|
|
52
|
+
]
|
|
53
|
+
}
|
|
54
|
+
]
|
|
55
|
+
}
|
package/test/runTests.test.js
CHANGED