@codesoul-co/hypha-memory / memory-server-permanent-migration-fixtures
- Package index:
@codesoul-co/hypha-memory - Source:
packages/memory/src/memory-server-permanent-migration-fixtures.ts - Exports: 6
Using this module
Use the Memory server permanent migration fixtures module for writing deterministic tests and contract assertions. It exports 1 constant, 2 functions, 2 interfaces, 1 type.
Import from the package entrypoint
import {
permanentMemoryFailureFixtures,
createPermanentMemoryMigrationAdapterHarness,
createReferencePermanentMemoryMigrationHarness,
} from '@codesoul-co/hypha-memory';
import type {
PermanentMemoryFailureFixture,
PermanentMemoryMigrationAcceptanceHarness,
PermanentMemoryMigrationHarnessFactory,
} from '@codesoul-co/hypha-memory';Usage patterns
- Use the 3 type/interface exports as static contracts in application code, adapters, or tests. Import them with
import type; they do not exist at runtime. - The module exposes 2 functions as direct operation entrypoints. Every overload, required/optional parameter, and return type is documented below.
- The 1 constant/enum export provides stable values, schemas, definitions, or defaults. Reuse these exports instead of copying internal values into an application.
Public exports
| Symbol | Kind | Signature | Description |
|---|---|---|---|
permanentMemoryFailureFixtures | constant | const permanentMemoryFailureFixtures: readonly PermanentMemoryFailureFixture[] | Permanent Memory Failure Fixtures constant exported by the memory-server-permanent-migration-fixtures module. |
createPermanentMemoryMigrationAdapterHarness | function | createPermanentMemoryMigrationAdapterHarness(fixture: PermanentMemoryFailureFixture): PermanentMemoryMigrationAcceptanceHarness | Create Permanent Memory Migration Adapter Harness function with 1 public call signature; parameters and return types are listed below. |
createReferencePermanentMemoryMigrationHarness | function | createReferencePermanentMemoryMigrationHarness(fixture: PermanentMemoryFailureFixture): PermanentMemoryMigrationAcceptanceHarness | Create Reference Permanent Memory Migration Harness function with 1 public call signature; parameters and return types are listed below. |
PermanentMemoryFailureFixture | interface | interface PermanentMemoryFailureFixture | Permanent Memory Failure Fixture interface with 10 public fields or methods. |
PermanentMemoryMigrationAcceptanceHarness | interface | interface PermanentMemoryMigrationAcceptanceHarness | Permanent Memory Migration Acceptance Harness interface with 2 public fields or methods. |
PermanentMemoryMigrationHarnessFactory | type | type PermanentMemoryMigrationHarnessFactory = (fixture: PermanentMemoryFailureFixture) => PermanentMemoryMigrationAcceptanceHarness | Public type alias for Permanent Memory Migration Harness Factory; the declaration contains its complete type expression. |
permanentMemoryFailureFixtures
Permanent Memory Failure Fixtures constant exported by the memory-server-permanent-migration-fixtures module.
- Kind: constant
- Import:
import { permanentMemoryFailureFixtures } from '@codesoul-co/hypha-memory'; - Source module:
memory-server-permanent-migration-fixtures
Declaration
export declare const permanentMemoryFailureFixtures: readonly PermanentMemoryFailureFixture[];createPermanentMemoryMigrationAdapterHarness
Create Permanent Memory Migration Adapter Harness function with 1 public call signature; parameters and return types are listed below.
- Kind: function
- Import:
import { createPermanentMemoryMigrationAdapterHarness } from '@codesoul-co/hypha-memory'; - Source module:
memory-server-permanent-migration-fixtures
Declaration
export declare function createPermanentMemoryMigrationAdapterHarness(fixture: PermanentMemoryFailureFixture): PermanentMemoryMigrationAcceptanceHarness;Call signature
createPermanentMemoryMigrationAdapterHarness(fixture: PermanentMemoryFailureFixture): PermanentMemoryMigrationAcceptanceHarnessParameters
| Parameter | Type | Required | Description |
|---|---|---|---|
fixture | PermanentMemoryFailureFixture | Yes | Required parameter; accepted values are defined by the type column. |
Returns
- Type:
PermanentMemoryMigrationAcceptanceHarness - Description: The return contract is defined by the type shown above.
createReferencePermanentMemoryMigrationHarness
Create Reference Permanent Memory Migration Harness function with 1 public call signature; parameters and return types are listed below.
- Kind: function
- Import:
import { createReferencePermanentMemoryMigrationHarness } from '@codesoul-co/hypha-memory'; - Source module:
memory-server-permanent-migration-fixtures
Declaration
export declare function createReferencePermanentMemoryMigrationHarness(fixture: PermanentMemoryFailureFixture): PermanentMemoryMigrationAcceptanceHarness;Call signature
createReferencePermanentMemoryMigrationHarness(fixture: PermanentMemoryFailureFixture): PermanentMemoryMigrationAcceptanceHarnessParameters
| Parameter | Type | Required | Description |
|---|---|---|---|
fixture | PermanentMemoryFailureFixture | Yes | Required parameter; accepted values are defined by the type column. |
Returns
- Type:
PermanentMemoryMigrationAcceptanceHarness - Description: The return contract is defined by the type shown above.
PermanentMemoryFailureFixture
Permanent Memory Failure Fixture interface with 10 public fields or methods.
- Kind: interface
- Import:
import type { PermanentMemoryFailureFixture } from '@codesoul-co/hypha-memory'; - Source module:
memory-server-permanent-migration-fixtures
Declaration
export interface PermanentMemoryFailureFixture {
id: string;
operation: PermanentMemoryMigrationOperation;
providerError: Record<string, unknown>;
expectedCode?: NormalizedMemoryError['code'];
expectedRetryable?: boolean;
expectedDisposition?: PermanentMemoryFailureDisposition;
expectedFinalState?: PermanentMemoryFailureFinalState;
expectedEmpty?: 'null' | 'array' | 'false';
attempt?: number;
maxAttempts?: number;
}Contract members
| Member | Kind | Signature | Description |
|---|---|---|---|
attempt | property | attempt?: number | Public property; its type, readonly modifier and optionality are shown in the signature. |
expectedCode | property | expectedCode?: "MEMORY_INVALID_INPUT" | "MEMORY_EXTRACTION_SOURCE_UNAVAILABLE" | "MEMORY_EXTRACTION_FAILED" | "MEMORY_EXTRACTION_CURSOR_CONFLICT" | "MEMORY_MAINTENANCE_CONFLICT" | "MEMORY_RANKING_FAILED" | "MEMORY_IDEMPOTENCY_CONFLICT" | "MEMORY_SCOPE_DENIED" | "MEMORY_PERMISSION_DENIED" | "MEMORY_NOT_FOUND" | "MEMORY_REVISION_CONFLICT" | "MEMORY_PROVIDER_NOT_INSTALLED" | "MEMORY_PROVIDER_UNAVAILABLE" | "MEMORY_PR... | Public property; its type, readonly modifier and optionality are shown in the signature. |
expectedDisposition | property | expectedDisposition?: PermanentMemoryFailureDisposition | Public property; its type, readonly modifier and optionality are shown in the signature. |
expectedEmpty | property | expectedEmpty?: "array" | "null" | "false" | Public property; its type, readonly modifier and optionality are shown in the signature. |
expectedFinalState | property | expectedFinalState?: PermanentMemoryFailureFinalState | Public property; its type, readonly modifier and optionality are shown in the signature. |
expectedRetryable | property | expectedRetryable?: boolean | Public property; its type, readonly modifier and optionality are shown in the signature. |
id | property | id: string | Public property; its type, readonly modifier and optionality are shown in the signature. |
maxAttempts | property | maxAttempts?: number | Public property; its type, readonly modifier and optionality are shown in the signature. |
operation | property | operation: PermanentMemoryMigrationOperation | Public property; its type, readonly modifier and optionality are shown in the signature. |
providerError | property | providerError: Record<string, unknown> | Public property; its type, readonly modifier and optionality are shown in the signature. |
PermanentMemoryMigrationAcceptanceHarness
Permanent Memory Migration Acceptance Harness interface with 2 public fields or methods.
- Kind: interface
- Import:
import type { PermanentMemoryMigrationAcceptanceHarness } from '@codesoul-co/hypha-memory'; - Source module:
memory-server-permanent-migration-fixtures
Declaration
export interface PermanentMemoryMigrationAcceptanceHarness {
port: PermanentMemoryMigrationPort;
events: PermanentMemoryFailureEvent[];
}Contract members
| Member | Kind | Signature | Description |
|---|---|---|---|
events | property | events: PermanentMemoryFailureEvent[] | Public property; its type, readonly modifier and optionality are shown in the signature. |
port | property | port: PermanentMemoryMigrationPort | Public property; its type, readonly modifier and optionality are shown in the signature. |
PermanentMemoryMigrationHarnessFactory
Public type alias for Permanent Memory Migration Harness Factory; the declaration contains its complete type expression.
- Kind: type
- Import:
import type { PermanentMemoryMigrationHarnessFactory } from '@codesoul-co/hypha-memory'; - Source module:
memory-server-permanent-migration-fixtures
Declaration
export type PermanentMemoryMigrationHarnessFactory = (fixture: PermanentMemoryFailureFixture) => PermanentMemoryMigrationAcceptanceHarness;