@augment-vir/assert 30.0.3 → 30.0.5
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/assertions/boolean.d.ts +2 -2
- package/dist/assertions/boundary.d.ts +2 -2
- package/dist/assertions/enum.d.ts +2 -2
- package/dist/assertions/equality/entry-equality.d.ts +2 -2
- package/dist/assertions/equality/json-equality.d.ts +2 -2
- package/dist/assertions/equality/json-equality.js +1 -1
- package/dist/assertions/equality/simple-equality.d.ts +2 -2
- package/dist/assertions/equality/ts-type-equality.d.ts +1 -1
- package/dist/assertions/extendable-assertions.d.ts +43 -914
- package/dist/assertions/http.d.ts +1 -1
- package/dist/assertions/instance.d.ts +3 -3
- package/dist/assertions/keys.d.ts +3 -3
- package/dist/assertions/keys.js +1 -1
- package/dist/assertions/length.d.ts +2 -2
- package/dist/assertions/nullish.d.ts +2 -2
- package/dist/assertions/output.d.ts +2 -2
- package/dist/assertions/primitive.d.ts +3 -3
- package/dist/assertions/promise.d.ts +1 -1
- package/dist/assertions/runtime-type.d.ts +9 -8
- package/dist/assertions/runtime-type.js +4 -4
- package/dist/assertions/throws.d.ts +2 -2
- package/dist/assertions/uuid.d.ts +2 -2
- package/dist/assertions/values.d.ts +2 -2
- package/dist/augments/guards/assert-wrap.d.ts +3 -254
- package/dist/augments/guards/assert.d.ts +4 -155
- package/dist/augments/guards/assert.js +6 -3
- package/dist/augments/guards/check-wrap.d.ts +4 -255
- package/dist/augments/guards/check-wrap.js +1 -1
- package/dist/augments/guards/check.d.ts +4 -255
- package/dist/augments/guards/wait-until.d.ts +3 -232
- package/dist/guard-types/assert-wrap-function.d.ts +2 -2
- package/dist/guard-types/check-function.d.ts +2 -2
- package/dist/guard-types/check-wrap-wrapper-function.d.ts +3 -3
- package/dist/guard-types/guard-override.d.ts +1 -1
- package/dist/guard-types/wait-until-function.d.ts +3 -4
- package/dist/index.d.ts +1 -1
- package/dist/test-timeout.mock.d.ts +2 -2
- package/package.json +2 -2
- package/dist/assertions/output.example.d.ts +0 -1
- package/dist/assertions/output.example.js +0 -13
- package/dist/assertions/runtime-type.example.d.ts +0 -1
- package/dist/assertions/runtime-type.example.js +0 -3
- package/dist/assertions/throws.example.d.ts +0 -1
- package/dist/assertions/throws.example.js +0 -11
- package/dist/augments/assertion.error.example.d.ts +0 -1
- package/dist/augments/assertion.error.example.js +0 -3
- package/dist/augments/guards/assert-wrap.example.d.ts +0 -1
- package/dist/augments/guards/assert-wrap.example.js +0 -9
- package/dist/augments/guards/assert.example.d.ts +0 -1
- package/dist/augments/guards/assert.example.js +0 -4
- package/dist/augments/guards/check-wrap.example.d.ts +0 -1
- package/dist/augments/guards/check-wrap.example.js +0 -9
- package/dist/augments/guards/check.example.d.ts +0 -1
- package/dist/augments/guards/check.example.js +0 -5
- package/dist/augments/guards/wait-until.example.d.ts +0 -1
- package/dist/augments/guards/wait-until.example.js +0 -13
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { MaybePromise, NarrowToExpected } from '@augment-vir/core';
|
|
1
|
+
import { type MaybePromise, type NarrowToExpected } from '@augment-vir/core';
|
|
2
2
|
import { autoGuardSymbol } from '../guard-types/guard-override.js';
|
|
3
|
-
import { WaitUntilOptions } from '../guard-types/wait-until-function.js';
|
|
3
|
+
import { type WaitUntilOptions } from '../guard-types/wait-until-function.js';
|
|
4
4
|
/**
|
|
5
5
|
* All falsy values in JavaScript. This does not include `NaN` because there is no dedicated type
|
|
6
6
|
* for it in TypeScript.
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { MaybePromise } from '@augment-vir/core';
|
|
2
|
-
import { WaitUntilOptions } from '../guard-types/wait-until-function.js';
|
|
1
|
+
import { type MaybePromise } from '@augment-vir/core';
|
|
2
|
+
import { type WaitUntilOptions } from '../guard-types/wait-until-function.js';
|
|
3
3
|
declare function endsWith<const ArrayElement>(parent: ReadonlyArray<ArrayElement>, child: ArrayElement, failureMessage?: string | undefined): void;
|
|
4
4
|
declare function endsWith(parent: string, child: string, failureMessage?: string | undefined): void;
|
|
5
5
|
declare function endsWith(parent: string | ReadonlyArray<string>, child: string, failureMessage?: string | undefined): void;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import type { NarrowToExpected } from '@augment-vir/core';
|
|
2
|
-
import { EnumBaseType, MaybePromise } from '@augment-vir/core';
|
|
3
|
-
import { WaitUntilOptions } from '../guard-types/wait-until-function.js';
|
|
2
|
+
import { type EnumBaseType, type MaybePromise } from '@augment-vir/core';
|
|
3
|
+
import { type WaitUntilOptions } from '../guard-types/wait-until-function.js';
|
|
4
4
|
export declare function isEnumValue<const Expected extends EnumBaseType>(child: unknown, checkEnum: Expected, failureMessage?: string | undefined): asserts child is Expected[keyof Expected];
|
|
5
5
|
declare function isNotEnumValue<const Actual, const Expected extends EnumBaseType>(child: Actual, checkEnum: Expected, failureMessage?: string | undefined): asserts child is Exclude<Actual, Expected[keyof Expected] | `${Expected[keyof Expected]}`>;
|
|
6
6
|
export declare const enumGuards: {
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import type { NarrowToExpected } from '@augment-vir/core';
|
|
2
|
-
import { MaybePromise } from '@augment-vir/core';
|
|
2
|
+
import { type MaybePromise } from '@augment-vir/core';
|
|
3
3
|
import { autoGuardSymbol } from '../../guard-types/guard-override.js';
|
|
4
|
-
import { WaitUntilOptions } from '../../guard-types/wait-until-function.js';
|
|
4
|
+
import { type WaitUntilOptions } from '../../guard-types/wait-until-function.js';
|
|
5
5
|
declare function entriesEqual<const Actual extends object, const Expected extends Actual>(actual: Actual, expected: Expected, failureMessage?: string | undefined): asserts actual is Expected;
|
|
6
6
|
declare function notEntriesEqual(actual: object, expected: object, failureMessage?: string | undefined): void;
|
|
7
7
|
export declare const entryEqualityGuards: {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { MaybePromise, NarrowToExpected } from '@augment-vir/core';
|
|
1
|
+
import { type MaybePromise, type NarrowToExpected } from '@augment-vir/core';
|
|
2
2
|
import { autoGuardSymbol } from '../../guard-types/guard-override.js';
|
|
3
|
-
import { WaitUntilOptions } from '../../guard-types/wait-until-function.js';
|
|
3
|
+
import { type WaitUntilOptions } from '../../guard-types/wait-until-function.js';
|
|
4
4
|
declare function jsonEquals<const Actual, const Expected extends Actual>(actual: Actual, expected: Expected, failureMessage?: string | undefined): asserts actual is Expected;
|
|
5
5
|
declare function notJsonEquals(actual: unknown, expected: unknown, failureMessage?: string | undefined): void;
|
|
6
6
|
export declare const jsonEqualityGuards: {
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { extractErrorMessage } from '@augment-vir/core';
|
|
1
|
+
import { extractErrorMessage, } from '@augment-vir/core';
|
|
2
2
|
import { AssertionError } from '../../augments/assertion.error.js';
|
|
3
3
|
import { autoGuard, autoGuardSymbol } from '../../guard-types/guard-override.js';
|
|
4
4
|
function baseJsonEquals(a, b) {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { MaybePromise, NarrowToExpected } from '@augment-vir/core';
|
|
1
|
+
import { type MaybePromise, type NarrowToExpected } from '@augment-vir/core';
|
|
2
2
|
import { autoGuardSymbol } from '../../guard-types/guard-override.js';
|
|
3
|
-
import { WaitUntilOptions } from '../../guard-types/wait-until-function.js';
|
|
3
|
+
import { type WaitUntilOptions } from '../../guard-types/wait-until-function.js';
|
|
4
4
|
export declare function strictEquals<const Actual, const Expected extends Actual>(actual: Actual, expected: Expected, failureMessage?: string | undefined): asserts actual is Expected;
|
|
5
5
|
declare function notStrictEquals(actual: unknown, expected: unknown, failureMessage?: string | undefined): void;
|
|
6
6
|
declare function looseEquals(actual: unknown, expected: unknown, failureMessage?: string | undefined): void;
|