public void setupLifecycle(Settings settings)

setup the LifeCycle collection

public void addReporter(
    string name, 
    Settings settings)

Adds an embeded reporter listener to the LifeCycle listeners collection

public const(TestCase)[][string] describeTests()

Returns an associative array of the detected tests, where the key is the suite name and the value is the TestCase

public const(TestCase)[][string] describeTests(const(TestCase)[] tests)

Returns an associative array of the detected tests, where the key is the suite name and the value is the TestCase

public string toJSONHierarchy(T)(const(T)[][string] items)
public runTests(
    const(TestCase)[] tests, 
    string testName = "", 
    string suiteName = "")

Runs the tests and returns the results

public runTests(string[] arguments)

Runs the tests and returns the results

public bool isSuccess(SuiteResult[] results)

Check if a suite result list is a success

Example

It should return true for an empty result

[].isSuccess.should.equal(true);

Example

It should return true if all the tests succeded

SuiteResult[] results = [ SuiteResult("") ];
results[0].tests = [ new TestResult("") ];
results[0].tests[0].status = TestResult.Status.success;

results.isSuccess.should.equal(true);

Example

It should return false if one the tests failed

SuiteResult[] results = [ SuiteResult("") ];
results[0].tests = [ new TestResult("") ];
results[0].tests[0].status = TestResult.Status.failure;

results.isSuccess.should.equal(false);

The main runner logic. You can find here some LifeCycle logic and test runner initalization

Copyright

© 2017 Szabo Bogdan

License

Subject to the terms of the MIT license, as written in the included LICENSE.txt file.

Authors

Szabo Bogdan