Commit 2fd49c3
fix: do not warn if an operation defines 400 and 422 responses (#38)
In `src/ruleset.ts`, change the `oneOf` schema to `anyOf`
Add test cases in `__tests__/owasp-api3-2019-define-error-validation.test.ts`:
* test with both `400` and `422`
* test with `4XX`
Co-authored-by: Nauman <[email protected]>1 parent 143d735 commit 2fd49c3
File tree
3 files changed
+56
-5637
lines changed- __tests__
- src
3 files changed
+56
-5637
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
42 | 42 | | |
43 | 43 | | |
44 | 44 | | |
| 45 | + | |
| 46 | + | |
| 47 | + | |
| 48 | + | |
| 49 | + | |
| 50 | + | |
| 51 | + | |
| 52 | + | |
| 53 | + | |
| 54 | + | |
| 55 | + | |
| 56 | + | |
| 57 | + | |
| 58 | + | |
| 59 | + | |
| 60 | + | |
| 61 | + | |
| 62 | + | |
| 63 | + | |
| 64 | + | |
| 65 | + | |
| 66 | + | |
| 67 | + | |
| 68 | + | |
| 69 | + | |
| 70 | + | |
| 71 | + | |
| 72 | + | |
| 73 | + | |
| 74 | + | |
| 75 | + | |
| 76 | + | |
| 77 | + | |
| 78 | + | |
| 79 | + | |
| 80 | + | |
| 81 | + | |
| 82 | + | |
| 83 | + | |
| 84 | + | |
| 85 | + | |
| 86 | + | |
| 87 | + | |
45 | 88 | | |
46 | 89 | | |
47 | 90 | | |
| |||
61 | 104 | | |
62 | 105 | | |
63 | 106 | | |
64 | | - | |
| 107 | + | |
65 | 108 | | |
66 | 109 | | |
67 | 110 | | |
| |||
0 commit comments