API Reference
Testimo
Testimo engine: discovery, execution, and reporting pipeline (configuration partial).
Inheritance
- Object
- Testimo
Constructors
public Testimo() #Methods
public Void AddRulesFromAssembly(Assembly asm) #VoidLoad and add all Rule subclasses from the provided assembly.
Parameters
- asm System.Reflection.Assembly
- Assembly containing custom rules.
ApplyRuleParameterOverrides(System.Collections.Generic.IEnumerable{TestimoX.Definitions.Rule} arg1) #Merges RuleOverrides values into each selected rule's Source.Parameters.
Parameters
- arg1 System.Collections.Generic.IEnumerable{TestimoX.Definitions.Rule}
EnsureDomainReadinessAsync() #Ensures each discovered domain has at least one healthy DC validated with quick RootDSE and a short subtree probe against the domain naming context. Warms the engine's health model so the preferred DCs for each domain start with a known-good server.
ExecuteWorkItemsAsync(System.Collections.Generic.IReadOnlyList{TestimoX.Testimo.RuleExecutionWorkItem} items, System.Threading.CancellationToken cancellationToken) #Executes a collection of rule work items using a bounded worker pool.
Parameters
- items System.Collections.Generic.IReadOnlyList{TestimoX.Testimo.RuleExecutionWorkItem}
- The work items to execute.
- cancellationToken System.Threading.CancellationToken
- Token used to stop scheduling additional work items.
Returns
A task that completes when all work items have been processed.
public static Testimo FromConfig(String configPath, String ruleConfigPath = null) #TestimoCreates a Testimo engine pre-configured from a configuration file (service.json or run.json).
Parameters
- configPath System.String
- ruleConfigPath System.String = null
public Boolean GenerateReportsOnDemand(Boolean html = false, Boolean word = false, Boolean open = true, String htmlPath = null, String wordPath = null) #BooleanGenerate HTML and/or Word reports on demand using the already collected run data. Does not re-execute rules; only renders outputs. Returns true when at least one artifact was generated successfully.
Parameters
- html System.Boolean = false
- word System.Boolean = false
- open System.Boolean = true
- htmlPath System.String = null
- wordPath System.String = null
public Void LoadConfig(String configPath, String ruleConfigPath = null) #VoidLoads a configuration file (service.json or run.json) and applies it to this instance. Prefer this unified method over the specialized loaders.
Parameters
- configPath System.String
- ruleConfigPath System.String = null
public Task<TestimoRunResult> RunAsync(CancellationToken ct = null) #Task<TestimoRunResult>Simplified instance API: run using properties (CSharpRules, PowerShellRules, RuleNames). Falls back to an empty selection if none provided.
Parameters
- ct System.Threading.CancellationToken = null
public Task<TestimoRunResult> RunAsync(CSharpRule[] csharpRules, PowerShellRule[] powershellRules, CancellationToken ct = null) #Task<TestimoRunResult>Convenience overload: run with typed rules.
Parameters
- csharpRules TestimoX.Definitions.CSharpRule[]
- powershellRules TestimoX.RulesPowerShell.PowerShellRule[]
- ct System.Threading.CancellationToken = null
public Task<TestimoRunResult> RunAsync(IEnumerable<String> ruleNames, CancellationToken ct = null) #Task<TestimoRunResult>Convenience overload: run with string rule names.
Parameters
- ruleNames System.Collections.Generic.IEnumerable{System.String}
- ct System.Threading.CancellationToken = null
public Task RunWithRuleNamesAsync(IEnumerable<String> ruleNames, CancellationToken ct = null) #TaskRuns rules by string names using the engine's modern pipeline.
Parameters
- ruleNames System.Collections.Generic.IEnumerable{System.String}
- Names of rules to include (case-insensitive).
- ct System.Threading.CancellationToken = null
- Cancellation token.
public async Task<RuleDiscoveryDebugInfo> ValidateRuleDiscovery(String[] includeRules = null, String[] excludeRules = null, CSharpRule[] includeCSharpRules = null, CSharpRule[] excludeCSharpRules = null) #Task<RuleDiscoveryDebugInfo>Performs rule discovery using the provided allow/deny filters and returns a RuleDiscoveryDebugInfo snapshot summarizing inputs and results. When no filters are supplied and rules already exist on the instance, the existing set is used and discovery is skipped.
Parameters
- includeRules System.String[] = null
- Optional PowerShell rule names to include.
- excludeRules System.String[] = null
- Optional PowerShell rule names to exclude.
- includeCSharpRules TestimoX.Definitions.CSharpRule[] = null
- Optional C# rules to include.
- excludeCSharpRules TestimoX.Definitions.CSharpRule[] = null
- Optional C# rules to exclude.
Returns
Debug information describing requested, available and final rules.
Inherited Methods
Properties
public RuleProfiler Profiler { get; } #Collects per-rule timing information for diagnostics and reports.
public StorageConfig Storage { get; set; } #Optional configuration enabling the durable results store for this run. When provided and Enabled is true, the engine will consult the store to reuse cached results and will write rule outputs as they complete. Default is null (disabled).
ResultStore #Active result store for this engine instance (no-op when storage is disabled).
public Int32 MaxConcurrentTasks { get; set; } #Maximum number of concurrent tasks to run
SupersededRulesSuppressed #Superseded rules that were suppressed during selection (for reporting only).
public List<String> Logs { get; set; } #Logs generated during the execution of the Testimo module
public ActiveDirectoryOverview ActiveDirectoryOverview { get; set; } #Summary of discovered Active Directory topology (forest, domains, DCs). Populated during discovery and used by rules and reporting.
public ActiveDirectoryDataServices ActiveDirectoryData { get; set; } #Underlying data access services for Active Directory discovery and queries.
public Boolean IncludeTrustedDomains { get; set; } #When true, discovery includes domains from trusted forests. Default is false.
public Boolean SkipGetInformation { get; set; } #Skip Active Directory discovery/overview phase. When enabled, the run proceeds with the current ActiveDirectoryOverview (if any) and rules that do not require discovery data.
public Boolean SkipPowerShellRules { get; set; } #Do not load or execute PowerShell-backed rules; only C# rules will run.
public String PowerShellRulesDirectory { get; set; } #Optional directory containing user-provided PowerShell rules. Overrides TESTIMOX_PS_RULES_DIR when set.
public Boolean IncludeSupersededRules { get; set; } #When true, include rules that are marked as superseded instead of suppressing them.
public Nullable<RuleSelectionProfile> SelectionProfile { get; set; } #Optional curated selection profile applied before explicit category/tag/cost filters.
public PowerShellRuntimeConfig PowerShellRuntime { get; set; } #Optional settings controlling how bundled PowerShell rules are materialized on disk. Hosts may override this per run to choose persistent, temporary, or disabled cache behavior.
public Boolean OpenReport { get; set; } #Open the generated HTML report in the default browser after the run.
public Boolean GenerateHtmlReport { get; set; } #Generate a rich HTML report after the run completes.
public Boolean GenerateWordReport { get; set; } #Generate a Word (.docx) report after the run completes.
public Boolean GenerateJsonReport { get; set; } #Generate a JSON summary report after the run completes.
public String JsonReportPath { get; set; } #Optional path to write a JSON report. If null, JSON is not produced.
public Nullable<Int32> OverallScore { get; set; } #Overall score calculated by the scoring engine for the last run.
public String HtmlReportPath { get; set; } #Optional path or filename for the HTML report. If not provided, an autogenerated name is used inside a local "Reports" folder.
public String WordReportPath { get; set; } #Optional path or filename for the Word report. If not provided, an autogenerated name is used inside a local "Reports" folder.
public String LicenseEdition { get; set; } #Optional license edition label used for this run (for example Community, Test, Trial, Premium, Enterprise). This is used for report attribution only; behavior is governed by the licensing engine.
public String LicenseSubject { get; set; } #Optional licensed-to subject (person or team) used for attribution in reports.
public String LicenseOrganization { get; set; } #Optional licensed-to organization used for attribution in reports.
public Nullable<DateTimeOffset> LicenseExpiresUtc { get; set; } #Optional license expiry timestamp in UTC used for display in reports.
public Nullable<DateTimeOffset> BuildSupportExpiryUtc { get; set; } #Optional build support window end timestamp in UTC used for display in reports.
public Nullable<Int32> LicenseConcurrencyCap { get; set; } #Optional concurrency cap derived from licensing semantics. When set, hosts or the runner may clamp MaxConcurrentTasks to this value before executing rule tasks.
public Nullable<Int32> RequestedConcurrency { get; set; } #Optional requested concurrency value before any license or policy caps were applied. Used only for diagnostics and banner output.
public Nullable<Boolean> LicenseAllowHtml { get; set; } #Optional flag indicating whether HTML report generation is permitted by the current license. When set to false, HTML reports are suppressed even when GenerateHtmlReport is true.
public Nullable<Boolean> LicenseAllowWord { get; set; } #Optional flag indicating whether Word report generation is permitted by the current license. When set to false, Word reports are suppressed even when GenerateWordReport is true.
public Nullable<Boolean> LicenseAllowJson { get; set; } #Optional flag indicating whether JSON report generation is permitted by the current license. When set to false, JSON reports are suppressed even when JsonReportPath is provided.
public CrosswalkSnapshot Crosswalk { get; set; } #Precomputed vendor crosswalk snapshot for this run (coverage, matches, docs). Built once before report generation.
public String ExportDirectory { get; set; } #Optional directory to which raw rule results will be exported as streaming JSON files. When set, each rule's primary result and any defined report sections are written separately.
public String[] IncludeDomains { get; set; } #Optional allow/deny lists for discovery and querying. When non-null, these are passed into ActiveDirectoryDataServices and respected by DC selection helpers.
public String[] ExcludeDomains { get; set; } #Domain DNS names to exclude during discovery/query.
public String[] IncludeDomainControllers { get; set; } #Specific DC hostnames to include during discovery/query.
public String[] ExcludeDomainControllers { get; set; } #Specific DC hostnames to exclude during discovery/query.
public String[] QueryIncludeDomainControllers { get; set; } #Optional DC allow/deny lists specifically for LDAP query routing (engine selection). When set, these take precedence over IncludeDomainControllers / ExcludeDomainControllers for query operations, while discovery/assessment can use their own lists.
public String[] QueryExcludeDomainControllers { get; set; } #Explicit DC exclude list for query operations (LDAP engine).
public String[] AssessIncludeDomainControllers { get; set; } #Optional DC allow/deny lists specifically for assessment/discovery (staging, summaries). When set, these take precedence over IncludeDomainControllers / ExcludeDomainControllers for Active Directory topology collection.
public String[] AssessExcludeDomainControllers { get; set; } #Explicit DC exclude list for discovery/assessment operations.
public TimeSpan TotalExecutionTime { get; set; } #Total execution time of the Testimo module
public String TotalExecutionTimeFormatted { get; } #Formatted execution time of the Testimo module
public OutputChannels Verbosity { get; set; } #Fine-grained output channels. Hosts should prefer VerbosityLevel.
public PreflightMode PreflightMode { get; set; } #LDAP preflight behavior. Default is Soft.
public Int32 PreflightTimeoutMs { get; set; } #LDAP preflight timeout (milliseconds). Applies to per-rule connectivity probe.
public VerbosityLevel VerbosityLevel { get; set; } #Primary verbosity knob: Quiet, Normal, Detailed, Debug.
public Boolean IsPowerShellModule { get; } #Check if the module is a PowerShell module
public CSharpRule[] CSharpRules { get; set; } #Optional list of C# rules to run. If null/empty and RuleNames is also null/empty, the engine runs without an explicit include filter.
public PowerShellRule[] PowerShellRules { get; set; } #Optional list of PowerShell rules to run (typed rule-set overloads).
public String[] RuleNames { get; set; } #Optional list of rule names to include. Applies to both C# and PowerShell rules.
public List<RuleConfig> RuleConfigs { get; set; } #Optional generic rule configs applied after discovery/selection.
public ConsoleView ConsoleView { get; set; } #High-level console view selection (Auto, Standard, Ansi). Auto picks Standard when interactive, Ansi otherwise.
public Boolean HideCompleted { get; set; } #When using the Spectre progress view (ConsoleView = Standard), controls whether completed rows are hidden from the live table while the run is in progress. Default is false (completed rows remain visible).
public EngineConfig Engine { get; set; } #Optional, strongly-typed engine settings (e.g., SYSVOL routing) applied for this instance. If provided, these values override global defaults and are applied during initialization.
public Category[] IncludeCategories { get; set; } #Optional category include filter applied during rule discovery/selection. When set, only rules with any of these categories are considered.
public Category[] ExcludeCategories { get; set; } #Optional category exclude filter applied during rule discovery/selection.
public String[] IncludeTags { get; set; } #Optional tag include filter; when set, only rules having any of these tags are considered.
public String[] ExcludeTags { get; set; } #Optional tag exclude filter; rules with any of these tags are excluded.
public Nullable<RuleCost> MaxRuleCost { get; set; } #Optional maximum cost hint for rules to include (e.g., Moderate). When set, rules with higher cost are excluded.
public Boolean ExcludeHeavyRules { get; set; } #When true, excludes rules marked as Heavy or Extreme regardless of MaxRuleCost.
public StagingMode StagingMode { get; set; } #Controls how AD dataset staging is performed relative to the progress view. Default is Sequential.
public TestimoStatus DefaultStatusTrue { get; set; } #Provide a default status for true
public TestimoStatus DefaultStatusFalse { get; set; } #Provide a default status for false
public Dictionary<String, Dictionary<String, Object>> RuleOverrides { get; set; } #Optional per-rule parameter overrides applied before rule execution. Keys are rule names; values are key/value pairs merged into Rule.Source.Parameters.
public Boolean StopAfterRuleDiscovery { get; set; } #When true, the engine stops after rule discovery and prints a detailed summary of requested/available/final rules without executing them. Useful for troubleshooting selection filters and provider configuration.