atef.config.PreparedToolConfiguration

class atef.config.PreparedToolConfiguration(cache: 'DataCache', parent: 'Optional[PreparedGroup]' = None, comparisons: 'List[PreparedSignalComparison]' = <factory>, prepare_failures: 'List[PreparedComparisonException]' = <factory>, combined_result: 'Result' = <factory>, config: 'ToolConfiguration' = <factory>)[source]
Attributes:
parent
result

Re-compute the combined result and return it

Methods

compare()

Run all comparisons and return a combined result.

from_config(config[, parent, cache])

Prepare a ToolConfiguration for running.

from_tool(tool, by_attr[, shared, parent, cache])

Prepare a Tool for running tests without an associated configuration.

walk_comparisons()

Walk through the prepared comparisons.

Methods

__init__(cache: ~atef.cache.DataCache, parent: ~atef.config.PreparedGroup | None = None, comparisons: ~typing.List[~atef.config.PreparedSignalComparison] = <factory>, prepare_failures: ~typing.List[~atef.exceptions.PreparedComparisonException] = <factory>, combined_result: ~atef.result.Result = <factory>, config: ~atef.config.ToolConfiguration = <factory>) None
async compare() Result

Run all comparisons and return a combined result.

classmethod from_config(config: ToolConfiguration, parent: PreparedGroup | None = None, cache: DataCache | None = None) PreparedToolConfiguration[source]

Prepare a ToolConfiguration for running.

Parameters:
configToolConfiguration

The tool configuration instance.

parentPreparedGroup, optional

The parent group, if available.

cacheDataCache, optional

The data cache instance, if available. If unspecified, a new data cache will be instantiated.

Returns:
PreparedToolConfiguration
classmethod from_tool(tool: Tool, by_attr: Dict[str, List[Comparison]], shared: List[Comparison] | None = None, parent: PreparedGroup | None = None, cache: DataCache | None = None) PreparedToolConfiguration[source]

Prepare a Tool for running tests without an associated configuration.

Parameters:
tooltools.Tool

The tool instance.

by_attrDict[str, List[Comparison]]

A dictionary of tool result attributes to comparisons.

sharedList[Comparison], optional

A list of comparisons to run on every key of the by_attr dictionary.

parentPreparedGroup, optional

The parent group, if available.

cacheDataCache, optional

The data cache instance, if available. If unspecified, a new data cache will be instantiated.

Returns:
PreparedToolConfiguration
walk_comparisons() Generator[PreparedComparison, None, None]

Walk through the prepared comparisons.

Attributes

parent: PreparedGroup | None = None

The hierarchical parent of this step.

result

Re-compute the combined result and return it

config: ToolConfiguration

The configuration settings.

comparisons: List[PreparedSignalComparison]

The comparisons to be run on the given devices.

prepare_failures: List[PreparedComparisonException]

The comparisons that failed to be prepared.

cache: DataCache

The data cache to use for the preparation step.

combined_result: Result

The result of all comparisons.