Header menu logo Xanthos

JvLinkStub Type

In-memory JV-Link emulator suitable for deterministic unit and property tests.

Constructors

Constructor Description

JvLinkStub()

Full Usage: JvLinkStub()

Returns: JvLinkStub
Returns: JvLinkStub

JvLinkStub(responses, ?totalSize, ?initialTimestamp)

Full Usage: JvLinkStub(responses, ?totalSize, ?initialTimestamp)

Parameters:
Returns: JvLinkStub
responses : Result<JvReadOutcome, ComError> seq
?totalSize : int64
?initialTimestamp : DateTime
Returns: JvLinkStub

Instance members

Instance member Description

this.ClearWatchEventFailure

Full Usage: this.ClearWatchEventFailure

Clears any configured WatchEvent failure.

this.ConfigureCourseFileResponse

Full Usage: this.ConfigureCourseFileResponse

Parameters:
    path : string
    explanation : string

path : string
explanation : string

this.ConfigureCurrentReadFileSize

Full Usage: this.ConfigureCurrentReadFileSize

Parameters:
    size : int64

size : int64

this.ConfigureJVLinkVersion

Full Usage: this.ConfigureJVLinkVersion

Parameters:
    version : string

version : string

this.ConfigureParentWindow

Full Usage: this.ConfigureParentWindow

Parameters:
handle : IntPtr

this.ConfigurePayoffDialogSuppressed

Full Usage: this.ConfigurePayoffDialogSuppressed

Parameters:
    flag : bool

flag : bool

this.ConfigureSaveFlag

Full Usage: this.ConfigureSaveFlag

Parameters:
    flag : bool

flag : bool

this.ConfigureTotalReadFileSize

Full Usage: this.ConfigureTotalReadFileSize

Parameters:
    bytes : int64

Adjusts the synthetic `TotalReadFileSize` that the stub will expose.

bytes : int64

this.ConfigureWatchEventFailure

Full Usage: this.ConfigureWatchEventFailure

Parameters:

Configures WatchEvent to fail with the specified error. Use to simulate COM event connection failures in tests.

error : ComError

this.CurrentSavePath

Full Usage: this.CurrentSavePath

Returns: string
Returns: string

this.Enqueue

Full Usage: this.Enqueue

Parameters:

Enqueues an additional response to be returned on subsequent `Read` calls.

response : Result<JvReadOutcome, ComError>

this.EnqueueMovieReadOutcome

Full Usage: this.EnqueueMovieReadOutcome

Parameters:

this.EnqueueRealtime

Full Usage: this.EnqueueRealtime

Parameters:

this.LastServiceKey

Full Usage: this.LastServiceKey

Returns: string option
Returns: string option

this.RaiseEvent

Full Usage: this.RaiseEvent

Parameters:
    key : string

Helper to trigger a watch event callback during tests.

key : string

this.UiDialogInvocationCount

Full Usage: this.UiDialogInvocationCount

Returns: int
Returns: int

this.UseMovieAvailabilityResponder

Full Usage: this.UseMovieAvailabilityResponder

Parameters:
responder : string -> Result<MovieAvailability, ComError>

this.UseMovieAvailabilityWithTypeResponder

Full Usage: this.UseMovieAvailabilityWithTypeResponder

Parameters:
responder : string * string -> Result<MovieAvailability, ComError>

this.UseMoviePlayResponder

Full Usage: this.UseMoviePlayResponder

Parameters:
responder : string * string option -> Result<unit, ComError>

this.UseSilksBinaryResponder

Full Usage: this.UseSilksBinaryResponder

Parameters:
responder : string -> Result<byte[] option, ComError>

this.UseSilksFileResponder

Full Usage: this.UseSilksFileResponder

Parameters:
responder : string * string -> Result<string option, ComError>

Static members

Static member Description

JvLinkStub.FromPayloads(payloads)

Full Usage: JvLinkStub.FromPayloads(payloads)

Parameters:
    payloads : byte[] seq

Returns: JvLinkStub

Helper to initialise the stub from raw payload bytes.

payloads : byte[] seq
Returns: JvLinkStub

Type something to start searching.