Arma Reforger Script API
Loading...
Searching...
No Matches
SCR_AutotestHarness Interface Reference

SCR_AutotestHarness is a thin wrapper around TestHarness, responsible for test instantiation and execution. More...

Inheritance diagram for SCR_AutotestHarness:

Static Public Member Functions

static void DebugPrintSuites ()
 Prints test suites and their test case state.
 
static void Begin (SCR_AutotestGroup testGroup, bool autorun=false, bool verboseLog=false)
 Configures the test runner to execute only the test suites present in the specified test group and initializes required structures.
 
static void Begin (notnull SCR_AutotestSuiteBase testSuite, bool autorun=false, bool verboseLog=false)
 Configures the test runner to execute single test suite and initializes required structures.
 
static void Begin (notnull SCR_AutotestCaseBase testCase, bool autorun=false, bool verboseLog=false)
 Configures the test runner to execute single test case and initializes required structures.
 
static SCR_AutotestReport Finish ()
 Signal that the test runner is finished. Does any necessary cleanup.
 
static void _SetActiveTestCase (TestBase testCase)
 Internal function. Sets active test case.
 
static TestBase ActiveTestCase ()
 Currently executed test case.
 
static SCR_AutotestPrinter GetLogger ()
 
static SCR_AutotestGroup GetDefaultTestGroupConfig ()
 Returns default test group for the project.
 

Static Public Attributes

static bool s_bIsRunning = false
 
static bool s_bOpenLogAfterRun = false
 
static bool s_bOpenDialogAfterRun = false
 
static bool s_bCloseGameAfterRun = true
 

Static Protected Attributes

static ref SCR_AutotestReport s_Report
 
static ref SCR_AutotestPrinter s_Logger
 
static TestBase s_ActiveTestCase
 

Detailed Description

SCR_AutotestHarness is a thin wrapper around TestHarness, responsible for test instantiation and execution.

if (SCR_AutotestHarness.Finished())
{
}
bool runFinished = SCR_AutotestHarness.Run();
PrintFormat("Run: %1", runFinished, level: LogLevel.DEBUG);
if (runFinished)
{
Print("Tests done", LogLevel.DEBUG);
}
Collection of test suites.
Definition SCR_AutotestGroup.c:4
SCR_AutotestHarness is a thin wrapper around TestHarness, responsible for test instantiation and exec...
Definition SCR_AutotestHarness.c:24
static void Begin(SCR_AutotestGroup testGroup, bool autorun=false, bool verboseLog=false)
Configures the test runner to execute only the test suites present in the specified test group and in...
Definition SCR_AutotestHarness.c:57
static SCR_AutotestGroup GetDefaultTestGroupConfig()
Returns default test group for the project.
Definition SCR_AutotestHarness.c:256
static void DebugPrintSuites()
Prints test suites and their test case state.
Definition SCR_AutotestHarness.c:37

Member Function Documentation

◆ _SetActiveTestCase()

static void SCR_AutotestHarness._SetActiveTestCase ( TestBase testCase)
static

Internal function. Sets active test case.

◆ ActiveTestCase()

static TestBase SCR_AutotestHarness.ActiveTestCase ( )
static

Currently executed test case.

◆ Begin() [1/3]

static void SCR_AutotestHarness.Begin ( notnull SCR_AutotestCaseBase testCase,
bool autorun = false,
bool verboseLog = false )
static

Configures the test runner to execute single test case and initializes required structures.

◆ Begin() [2/3]

static void SCR_AutotestHarness.Begin ( notnull SCR_AutotestSuiteBase testSuite,
bool autorun = false,
bool verboseLog = false )
static

Configures the test runner to execute single test suite and initializes required structures.

◆ Begin() [3/3]

static void SCR_AutotestHarness.Begin ( SCR_AutotestGroup testGroup,
bool autorun = false,
bool verboseLog = false )
static

Configures the test runner to execute only the test suites present in the specified test group and initializes required structures.

◆ DebugPrintSuites()

static void SCR_AutotestHarness.DebugPrintSuites ( )
static

Prints test suites and their test case state.

◆ Finish()

static SCR_AutotestReport SCR_AutotestHarness.Finish ( )
static

Signal that the test runner is finished. Does any necessary cleanup.

◆ GetDefaultTestGroupConfig()

static SCR_AutotestGroup SCR_AutotestHarness.GetDefaultTestGroupConfig ( )
static

Returns default test group for the project.

Should be overridden in project specific addon.

◆ GetLogger()

static SCR_AutotestPrinter SCR_AutotestHarness.GetLogger ( )
static

Member Data Documentation

◆ s_ActiveTestCase

TestBase SCR_AutotestHarness.s_ActiveTestCase
staticprotected

◆ s_bCloseGameAfterRun

bool SCR_AutotestHarness.s_bCloseGameAfterRun = true
static

◆ s_bIsRunning

bool SCR_AutotestHarness.s_bIsRunning = false
static

◆ s_bOpenDialogAfterRun

bool SCR_AutotestHarness.s_bOpenDialogAfterRun = false
static

◆ s_bOpenLogAfterRun

bool SCR_AutotestHarness.s_bOpenLogAfterRun = false
static

◆ s_Logger

ref SCR_AutotestPrinter SCR_AutotestHarness.s_Logger
staticprotected

◆ s_Report

ref SCR_AutotestReport SCR_AutotestHarness.s_Report
staticprotected

The documentation for this interface was generated from the following file: