@event-driven-io/emmett-postgresql 0.23.0-alpha.2 → 0.23.0-alpha.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/dist/index.cjs CHANGED
@@ -365,7 +365,7 @@ function assertEqual(expected, actual, message) {
365
365
  throw new AssertionError(
366
366
  `${_nullishCoalesce(message, () => ( "Objects are not equal"))}:
367
367
  Expected: ${JSONParser.stringify(expected)}
368
- Actual:${JSONParser.stringify(actual)}`
368
+ Actual: ${JSONParser.stringify(actual)}`
369
369
  );
370
370
  }
371
371
  function assertNotEqual(obj, other, message) {
@@ -380,8 +380,12 @@ function assertIsNotNull(result) {
380
380
  }
381
381
  var assertThatArray = (array) => {
382
382
  return {
383
- isEmpty: () => assertEqual(array.length, 0),
384
- isNotEmpty: () => assertNotEqual(array.length, 0),
383
+ isEmpty: () => assertEqual(
384
+ array.length,
385
+ 0,
386
+ `Array is not empty ${JSONParser.stringify(array)}`
387
+ ),
388
+ isNotEmpty: () => assertNotEqual(array.length, 0, `Array is empty`),
385
389
  hasSize: (length) => assertEqual(array.length, length),
386
390
  containsElements: (other) => {
387
391
  assertTrue(other.every((ts) => array.some((o) => deepEquals(ts, o))));
@@ -390,7 +394,7 @@ var assertThatArray = (array) => {
390
394
  assertTrue(other.every((ts) => array.some((o) => isSubset(o, ts))));
391
395
  },
392
396
  containsOnlyElementsMatching: (other) => {
393
- assertEqual(array.length, other.length);
397
+ assertEqual(array.length, other.length, `Arrays lengths don't match`);
394
398
  assertTrue(other.every((ts) => array.some((o) => isSubset(o, ts))));
395
399
  },
396
400
  containsExactlyInAnyOrder: (other) => {
@@ -471,7 +475,7 @@ var assertDocumentsEqual = (actual, expected) => {
471
475
  expected._id,
472
476
  actual._id,
473
477
  // eslint-disable-next-line @typescript-eslint/restrict-template-expressions
474
- `Document ids are not matching! Expected: ${expected._id}, actual: ${actual._id}`
478
+ `Document ids are not matching! Expected: ${expected._id}, Actual: ${actual._id}`
475
479
  );
476
480
  return assertDeepEqual(
477
481
  withoutIdAndVersion(actual),