nock 15.0.0-beta.13 → 15.0.0-beta.15

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.
@@ -348,6 +348,9 @@ const dataEqual = (expected , actual ) => {
348
348
  function deepEqual(expected , actual ) {
349
349
  debug('deepEqual comparing', typeof expected, expected, typeof actual, actual)
350
350
  if (expected instanceof RegExp) {
351
+ if (expected.global || expected.sticky) {
352
+ expected.lastIndex = 0
353
+ }
351
354
  return expected.test(actual)
352
355
  }
353
356
 
@@ -467,6 +470,8 @@ const expand = (input ) => {
467
470
  } else {
468
471
  resultPtr[part] = {}
469
472
  }
473
+ } else if (typeof resultPtr[part] !== 'object') {
474
+ return undefined
470
475
  }
471
476
  resultPtr = resultPtr[part]
472
477
  }
package/package.json CHANGED
@@ -7,7 +7,7 @@
7
7
  "testing",
8
8
  "isolation"
9
9
  ],
10
- "version": "15.0.0-beta.13",
10
+ "version": "15.0.0-beta.15",
11
11
  "author": "Pedro Teixeira <pedro.teixeira@gmail.com>",
12
12
  "repository": {
13
13
  "type": "git",