RuntimeTest Type — svelte Architecture
Architecture documentation for the RuntimeTest type/interface in shared.ts from the svelte codebase.
Entity Profile
Dependency Diagram
graph TD 7f3e9a37_5b56_cb2c_c488_75716bde2c43["RuntimeTest"] 2cf8977f_8bb9_9ef1_6e90_d6eea1dac831["shared.ts"] 7f3e9a37_5b56_cb2c_c488_75716bde2c43 -->|defined in| 2cf8977f_8bb9_9ef1_6e90_d6eea1dac831 style 7f3e9a37_5b56_cb2c_c488_75716bde2c43 fill:#6366f1,stroke:#818cf8,color:#fff
Relationship Graph
Source Code
packages/svelte/tests/runtime-legacy/shared.ts lines 44–104
export interface RuntimeTest<Props extends Record<string, any> = Record<string, any>>
extends BaseTest {
/** Use e.g. `mode: ['client']` to indicate that this test should never run in server/hydrate modes */
mode?: Array<'server' | 'async-server' | 'client' | 'hydrate'>;
/** Temporarily skip specific modes, without skipping the entire test */
skip_mode?: Array<'server' | 'async-server' | 'client' | 'hydrate'>;
/** Skip if running with process.env.SVELTE_NO_ASYNC */
skip_no_async?: boolean;
/** Skip if running without process.env.SVELTE_NO_ASYNC */
skip_async?: boolean;
html?: string;
ssrHtml?: string;
compileOptions?: Partial<CompileOptions>;
props?: Props;
server_props?: Props;
id_prefix?: string;
before_test?: () => void;
after_test?: () => void;
test?: (args: {
variant: 'dom' | 'hydrate';
assert: Assert;
compileOptions: CompileOptions;
component: Props & {
[key: string]: any;
};
instance: Record<string, any>;
mod: any;
ok: typeof ok;
raf: {
tick: (ms: number) => void;
};
target: HTMLElement;
window: Window & {
Event: typeof Event;
InputEvent: typeof InputEvent;
KeyboardEvent: typeof KeyboardEvent;
MouseEvent: typeof MouseEvent;
};
logs: any[];
warnings: any[];
errors: any[];
hydrate: Function;
}) => void | Promise<void>;
test_ssr?: (args: {
logs: any[];
warnings: any[];
assert: Assert;
variant: 'ssr' | 'async-ssr';
}) => void | Promise<void>;
accessors?: boolean;
immutable?: boolean;
intro?: boolean;
load_compiled?: boolean;
error?: string;
runtime_error?: string;
warnings?: string[];
errors?: string[];
expect_unhandled_rejections?: boolean;
withoutNormalizeHtml?: boolean | 'only-strip-comments';
recover?: boolean;
}
Source
Frequently Asked Questions
What is the RuntimeTest type?
RuntimeTest is a type/interface in the svelte codebase, defined in packages/svelte/tests/runtime-legacy/shared.ts.
Where is RuntimeTest defined?
RuntimeTest is defined in packages/svelte/tests/runtime-legacy/shared.ts at line 44.
Analyze Your Own Codebase
Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.
Try Supermodel Free