mockaton 8.2.3 → 8.2.4

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/README.md CHANGED
@@ -393,6 +393,9 @@ await mockaton.select('api/foo.200.GET.json')
393
393
  ```js
394
394
  await mockaton.bulkSelectByComment('(demo-a)')
395
395
  ```
396
+ Parentheses are optional. You can pass a partial match.
397
+ For example, passing `'demo-'` (without the final `a`), selects the
398
+ first mock in alphabetical order that matches.
396
399
 
397
400
  ### Set Route is Delayed Flag
398
401
  ```js
package/package.json CHANGED
@@ -2,7 +2,7 @@
2
2
  "name": "mockaton",
3
3
  "description": "A deterministic server-side for developing and testing frontend clients",
4
4
  "type": "module",
5
- "version": "8.2.3",
5
+ "version": "8.2.4",
6
6
  "main": "index.js",
7
7
  "types": "index.d.ts",
8
8
  "license": "MIT",
@@ -212,8 +212,11 @@ async function runTests() {
212
212
  ['/api/alternative', 'api/alternative(comment-2).GET.200.json', { comment: 2 }],
213
213
  ['/api/my-route', 'api/my-route(comment-2).GET.200.json', { comment: 2 }]
214
214
  ])
215
-
215
+ await testItBulkSelectsByComment('mment-1', [ // partial match within parentheses
216
+ ['/api/alternative', 'api/alternative(comment-1).GET.200.json', 'With_Comment_1']
217
+ ])
216
218
  await commander.reset()
219
+
217
220
  for (const [url, file, body] of fixtures)
218
221
  await testMockDispatching(url, file, body)
219
222