singer_sdk.testing.runners.TapTestRunner

class singer_sdk.testing.runners.TapTestRunner[source]

Utility class to simplify tap testing.

__init__(tap_class, config=None, suite_config=None, **kwargs)[source]

Initialize Tap instance.

Parameters:
  • tap_class (type[Tap]) – Tap class to run.

  • config (dict | None) – Config dict to pass to Tap class.

  • suite_config (SuiteConfig) – SuiteConfig instance to be used when instantiating tests.

  • kwargs (Any) – Default arguments to be passed to tap on create.

Return type:

None

new_tap()[source]

Get new Tap instance.

Returns:

A configured Tap instance.

Return type:

Tap

run_connection_test()[source]

Run tap connection test.

Returns:

True if connection test passes, else False.

Return type:

bool

run_discovery()[source]

Run tap discovery.

Returns:

The catalog as a string.

Return type:

str

run_sync_dry_run()[source]

Run tap sync dry run.

Returns:

True if dry run test passes, else False.

Return type:

bool

sync_all(**kwargs)[source]

Run a full tap sync, assigning output to the runner object.

Parameters:

kwargs (Any) – Unused keyword arguments.

Return type:

None