Skip to content

Ts.Assert.awaited.not.sub

Import

typescript
import { Ts } from '@wollybeard/kit'

// Access via namespace
Ts.Assert.awaited.not.sub
typescript
import { sub } from '@wollybeard/kit/ts'

Functions

[F] ofAs

typescript
<$Type>(): DispatchAfterInput<State.SetExpectedType<State.SetRelator<State.SetNegated<State.AddExtractor<State.Empty, Awaited$>>, SubKind>, $Type>>

Constants

[C] any

typescript
InputActualAsValueNarrow<
  State.SetExpectedType<
    State.SetAllowAny<
      State.SetRelator<
        State.SetNegated<State.AddExtractor<State.Empty, Awaited$>>,
        SubKind
      >
    >,
    any
  >
>

[C] bigint

typescript
InputActualAsValueNarrow<
  State.SetExpectedType<
    State.SetRelator<
      State.SetNegated<State.AddExtractor<State.Empty, Awaited$>>,
      SubKind
    >,
    bigint
  >
>

[C] boolean

typescript
InputActualAsValueNarrow<
  State.SetExpectedType<
    State.SetRelator<
      State.SetNegated<State.AddExtractor<State.Empty, Awaited$>>,
      SubKind
    >,
    boolean
  >
>

[C] Date

typescript
InputActualAsValueNarrow<
  State.SetExpectedType<
    State.SetRelator<
      State.SetNegated<State.AddExtractor<State.Empty, Awaited$>>,
      SubKind
    >,
    Date
  >
>

[C] Error

typescript
InputActualAsValueNarrow<
  State.SetExpectedType<
    State.SetRelator<
      State.SetNegated<State.AddExtractor<State.Empty, Awaited$>>,
      SubKind
    >,
    Error
  >
>

[C] never

typescript
InputActualAsValueNarrow<
  State.SetExpectedType<
    State.SetAllowNever<
      State.SetRelator<
        State.SetNegated<State.AddExtractor<State.Empty, Awaited$>>,
        SubKind
      >
    >,
    never
  >
>

[C] null

typescript
InputActualAsValueNarrow<
  State.SetExpectedType<
    State.SetRelator<
      State.SetNegated<State.AddExtractor<State.Empty, Awaited$>>,
      SubKind
    >,
    null
  >
>

[C] number

typescript
InputActualAsValueNarrow<
  State.SetExpectedType<
    State.SetRelator<
      State.SetNegated<State.AddExtractor<State.Empty, Awaited$>>,
      SubKind
    >,
    number
  >
>

[C] of

typescript
InputExpectedAsValueNarrow<
  State.SetRelator<
    State.SetNegated<State.AddExtractor<State.Empty, Awaited$>>,
    SubKind
  >
>

[C] RegExp

typescript
InputActualAsValueNarrow<
  State.SetExpectedType<
    State.SetRelator<
      State.SetNegated<State.AddExtractor<State.Empty, Awaited$>>,
      SubKind
    >,
    RegExp
  >
>

[C] string

typescript
InputActualAsValueNarrow<
  State.SetExpectedType<
    State.SetRelator<
      State.SetNegated<State.AddExtractor<State.Empty, Awaited$>>,
      SubKind
    >,
    string
  >
>

[C] symbol

typescript
InputActualAsValueNarrow<
  State.SetExpectedType<
    State.SetRelator<
      State.SetNegated<State.AddExtractor<State.Empty, Awaited$>>,
      SubKind
    >,
    symbol
  >
>

[C] undefined

typescript
InputActualAsValueNarrow<
  State.SetExpectedType<
    State.SetRelator<
      State.SetNegated<State.AddExtractor<State.Empty, Awaited$>>,
      SubKind
    >,
    undefined
  >
>

[C] unknown

typescript
InputActualAsValueNarrow<
  State.SetExpectedType<
    State.SetAllowUnknown<
      State.SetRelator<
        State.SetNegated<State.AddExtractor<State.Empty, Awaited$>>,
        SubKind
      >
    >,
    unknown
  >
>

Types

[T] any

typescript
type any_<$Actual> = Kind.Apply<
  SubKind,
  [any, Kind.Apply<Path.Awaited$, [$Actual]>, true]
>

Pre-curried matcher for any. Extraction chain: Promise → T

Examples:

typescript
// ✓ Pass
type 
_
= Assert.awaited.sub.
any
<
Promise
<any>>
// ✗ Fail type
_
= Assert.awaited.sub.
any
<
Promise
<string>>

[T] bigint

typescript
type bigint_<$Actual> = Kind.Apply<
  SubKind,
  [bigint, Kind.Apply<Path.Awaited$, [$Actual]>, true]
>

Pre-curried matcher for bigint. Extraction chain: Promise → T

Examples:

typescript
// ✓ Pass
type 
_
= Assert.awaited.sub.
bigint
<
Promise
<bigint>>
// ✗ Fail type
_
= Assert.awaited.sub.
bigint
<
Promise
<string>>

[T] boolean

typescript
type boolean_<$Actual> = Kind.Apply<
  SubKind,
  [boolean, Kind.Apply<Path.Awaited$, [$Actual]>, true]
>

Pre-curried matcher for boolean. Extraction chain: Promise → T

Examples:

typescript
// ✓ Pass
type 
_
= Assert.awaited.sub.
boolean
<
Promise
<boolean>>
// ✗ Fail type
_
= Assert.awaited.sub.
boolean
<
Promise
<string>>

[T] Date

typescript
type Date_<$Actual> = Kind.Apply<
  SubKind,
  [Date, Kind.Apply<Path.Awaited$, [$Actual]>, true]
>

Pre-curried matcher for Date. Extraction chain: Promise → T

Examples:

typescript
// ✓ Pass
type 
_
= Assert.awaited.sub.
Date
<
Promise
<Date>>
// ✗ Fail type
_
= Assert.awaited.sub.
Date
<
Promise
<string>>

[T] Error

typescript
type Error_<$Actual> = Kind.Apply<
  SubKind,
  [Error, Kind.Apply<Path.Awaited$, [$Actual]>, true]
>

Pre-curried matcher for Error. Extraction chain: Promise → T

Examples:

typescript
// ✓ Pass
type 
_
= Assert.awaited.sub.
Error
<
Promise
<Error>>
// ✗ Fail type
_
= Assert.awaited.sub.
Error
<
Promise
<string>>

[T] never

typescript
type never_<$Actual> = Kind.Apply<
  SubKind,
  [never, Kind.Apply<Path.Awaited$, [$Actual]>, true]
>

Pre-curried matcher for never. Extraction chain: Promise → T

Examples:

typescript
// ✓ Pass
type 
_
= Assert.awaited.sub.
never
<
Promise
<never>>
// ✗ Fail type
_
= Assert.awaited.sub.
never
<
Promise
<string>>

[T] null

typescript
type null_<$Actual> = Kind.Apply<
  SubKind,
  [null, Kind.Apply<Path.Awaited$, [$Actual]>, true]
>

Pre-curried matcher for null. Extraction chain: Promise → T

Examples:

typescript
// ✓ Pass
type 
_
= Assert.awaited.sub.
null
<
Promise
<null>>
// ✗ Fail type
_
= Assert.awaited.sub.
null
<
Promise
<string>>

[T] number

typescript
type number_<$Actual> = Kind.Apply<
  SubKind,
  [number, Kind.Apply<Path.Awaited$, [$Actual]>, true]
>

Pre-curried matcher for number. Extraction chain: Promise → T

Examples:

typescript
// ✓ Pass
type 
_
= Assert.awaited.sub.
number
<
Promise
<number>>
// ✗ Fail type
_
= Assert.awaited.sub.
number
<
Promise
<string>>

[T] of

typescript
type of_<$Expected, $Actual> = Kind.Apply<
  SubKind,
  [$Expected, Kind.Apply<Path.Awaited$, [$Actual]>, true]
>

awaited + sub relation matchers.

Extraction: extracts the resolved type from a Promise Relation: subtype relation (extends)

[T] RegExp

typescript
type RegExp_<$Actual> = Kind.Apply<
  SubKind,
  [RegExp, Kind.Apply<Path.Awaited$, [$Actual]>, true]
>

Pre-curried matcher for RegExp. Extraction chain: Promise → T

Examples:

typescript
// ✓ Pass
type 
_
= Assert.awaited.sub.
RegExp
<
Promise
<RegExp>>
// ✗ Fail type
_
= Assert.awaited.sub.
RegExp
<
Promise
<string>>

[T] string

typescript
type string_<$Actual> = Kind.Apply<
  SubKind,
  [string, Kind.Apply<Path.Awaited$, [$Actual]>, true]
>

Pre-curried matcher for string. Extraction chain: Promise → T

Examples:

typescript
// ✓ Pass
type 
_
= Assert.awaited.sub.
string
<
Promise
<string>>
// ✗ Fail type
_
= Assert.awaited.sub.
string
<
Promise
<number>>

[T] symbol

typescript
type symbol_<$Actual> = Kind.Apply<
  SubKind,
  [symbol, Kind.Apply<Path.Awaited$, [$Actual]>, true]
>

Pre-curried matcher for symbol. Extraction chain: Promise → T

Examples:

typescript
// ✓ Pass
type 
_
= Assert.awaited.sub.
symbol
<
Promise
<symbol>>
// ✗ Fail type
_
= Assert.awaited.sub.
symbol
<
Promise
<string>>

[T] undefined

typescript
type undefined_<$Actual> = Kind.Apply<
  SubKind,
  [undefined, Kind.Apply<Path.Awaited$, [$Actual]>, true]
>

Pre-curried matcher for undefined. Extraction chain: Promise → T

Examples:

typescript
// ✓ Pass
type 
_
= Assert.awaited.sub.
undefined
<
Promise
<undefined>>
// ✗ Fail type
_
= Assert.awaited.sub.
undefined
<
Promise
<string>>

[T] unknown

typescript
type unknown_<$Actual> = Kind.Apply<
  SubKind,
  [unknown, Kind.Apply<Path.Awaited$, [$Actual]>, true]
>

Pre-curried matcher for unknown. Extraction chain: Promise → T

Examples:

typescript
// ✓ Pass
type 
_
= Assert.awaited.sub.
unknown
<
Promise
<unknown>>
// ✗ Fail type
_
= Assert.awaited.sub.
unknown
<
Promise
<string>>