Skip to main content

get_tests

Auto-generated from the Python tool registry. Do not hand-edit outside <!-- examples:start --><!-- examples:end --> blocks — the generator (tools/generate_docs_reference.py) will overwrite them.

Group: testing  ·  Module: services.tools.get_tests

Maturity: stable (support status; independent of enabled state, readiness and permissions).

Description​

Lists Unity tests without running them. Returns one page with totalCount, nextCursor, hasMore and partial; pass nextCursor as cursor to read further pages. Omit mode to discover both EditMode and PlayMode tests.

Parameters​

NameTypeRequiredDescription
modeLiteral['EditMode', 'PlayMode'] | None—Filter by test mode; omit to include both modes.
name_patternstr | None—Case-insensitive substring of the test name or full name (not regex).
page_sizeint—Maximum tests per page (1..200).
cursorint—Zero-based offset; use the previous nextCursor.
timeout_secondsint—Total discovery observation budget in seconds, including both modes (default 300).
unity_instancestr | int | None—Target Unity instance for this call: Name@hash or hash prefix; an integer selects only that exact port over stdio and is rejected over HTTP. Read mcpforunity://instances for available targets. Omit to use the legacy active selection or the sole available instance.

Returns​

A dict containing the Unity response. The exact shape depends on the action.

Examples​

List the first 25 Edit Mode tests. Use the returned cursor if more items are available before choosing test selectors.

MCP arguments
{
"mode": "EditMode",
"page_size": 25
}