IGLib
1.7.2
The IGLib base library EXTENDED - with other lilbraries and applications.
|
Provide the context information of the current test. This is an adapter for the internal ExecutionContext class, hiding the internals from the user test. More...
Classes | |
class | ResultAdapter |
ResultAdapter adapts a TestResult for consumption by the user test code. More... | |
class | TestAdapter |
TestAdapter adapts a Test for consumption by the user test code. More... | |
Public Member Functions | |
TestContext (TestExecutionContext testExecutionContext) | |
Construct a TestContext for an ExecutionContext More... | |
Static Public Member Functions | |
static void | Write (bool value) |
Write the string representation of a boolean value to the current result More... | |
static void | Write (char value) |
Write a char to the current result More... | |
static void | Write (char[] value) |
Write a char array to the current result More... | |
static void | Write (double value) |
Write the string representation of a double to the current result More... | |
static void | Write (Int32 value) |
Write the string representation of an Int32 value to the current result More... | |
static void | Write (Int64 value) |
Write the string representation of an Int64 value to the current result More... | |
static void | Write (decimal value) |
Write the string representation of a decimal value to the current result More... | |
static void | Write (object value) |
Write the string representation of an object to the current result More... | |
static void | Write (Single value) |
Write the string representation of a Single value to the current result More... | |
static void | Write (string value) |
Write a string to the current result More... | |
static void | Write (UInt32 value) |
Write the string representation of a UInt32 value to the current result More... | |
static void | Write (UInt64 value) |
Write the string representation of a UInt64 value to the current result More... | |
static void | Write (string format, object arg1) |
Write a formatted string to the current result More... | |
static void | Write (string format, object arg1, object arg2) |
Write a formatted string to the current result More... | |
static void | Write (string format, object arg1, object arg2, object arg3) |
Write a formatted string to the current result More... | |
static void | Write (string format, params object[] args) |
Write a formatted string to the current result More... | |
static void | WriteLine () |
Write a line terminator to the current result More... | |
static void | WriteLine (bool value) |
Write the string representation of a boolean value to the current result followed by a line terminator More... | |
static void | WriteLine (char value) |
Write a char to the current result followed by a line terminator More... | |
static void | WriteLine (char[] value) |
Write a char array to the current result followed by a line terminator More... | |
static void | WriteLine (double value) |
Write the string representation of a double to the current result followed by a line terminator More... | |
static void | WriteLine (Int32 value) |
Write the string representation of an Int32 value to the current result followed by a line terminator More... | |
static void | WriteLine (Int64 value) |
Write the string representation of an Int64 value to the current result followed by a line terminator More... | |
static void | WriteLine (decimal value) |
Write the string representation of a decimal value to the current result followed by a line terminator More... | |
static void | WriteLine (object value) |
Write the string representation of an object to the current result followed by a line terminator More... | |
static void | WriteLine (Single value) |
Write the string representation of a Single value to the current result followed by a line terminator More... | |
static void | WriteLine (string value) |
Write a string to the current result followed by a line terminator More... | |
static void | WriteLine (UInt32 value) |
Write the string representation of a UInt32 value to the current result followed by a line terminator More... | |
static void | WriteLine (UInt64 value) |
Write the string representation of a UInt64 value to the current result followed by a line terminator More... | |
static void | WriteLine (string format, object arg1) |
Write a formatted string to the current result followed by a line terminator More... | |
static void | WriteLine (string format, object arg1, object arg2) |
Write a formatted string to the current result followed by a line terminator More... | |
static void | WriteLine (string format, object arg1, object arg2, object arg3) |
Write a formatted string to the current result followed by a line terminator More... | |
static void | WriteLine (string format, params object[] args) |
Write a formatted string to the current result followed by a line terminator More... | |
Properties | |
static TestContext | CurrentContext [get] |
Get the current test context. This is created as needed. The user may save the context for use within a test, but it should not be used outside the test for which it is created. More... | |
static TextWriter | Out [get] |
Gets a TextWriter that will send output to the current test result. More... | |
TestAdapter | Test [get] |
Get a representation of the current test. More... | |
ResultAdapter | Result [get] |
Gets a Representation of the TestResult for the current test. More... | |
string | TestDirectory [get] |
Gets the directory containing the current test assembly. More... | |
string | WorkDirectory [get] |
Gets the directory to be used for outputting files created by this test run. More... | |
Randomizer | Random [get] |
Gets the random generator. More... | |
Private Attributes | |
readonly TestExecutionContext | _testExecutionContext |
TestAdapter | _test |
ResultAdapter | _result |
Provide the context information of the current test. This is an adapter for the internal ExecutionContext class, hiding the internals from the user test.
|
inline |
Construct a TestContext for an ExecutionContext
testExecutionContext | The ExecutionContext to adapt |
|
inlinestatic |
Write the string representation of a boolean value to the current result
Referenced by NUnit.Framework.Tests.TestContextTests.TestContextWrite_WritesToResult().
|
inlinestatic |
Write a char to the current result
|
inlinestatic |
Write a char array to the current result
|
inlinestatic |
Write the string representation of a double to the current result
|
inlinestatic |
Write the string representation of an Int32 value to the current result
|
inlinestatic |
Write the string representation of an Int64 value to the current result
|
inlinestatic |
Write the string representation of a decimal value to the current result
|
inlinestatic |
Write the string representation of an object to the current result
|
inlinestatic |
Write the string representation of a Single value to the current result
|
inlinestatic |
Write a string to the current result
|
inlinestatic |
Write the string representation of a UInt32 value to the current result
|
inlinestatic |
Write the string representation of a UInt64 value to the current result
|
inlinestatic |
Write a formatted string to the current result
|
inlinestatic |
Write a formatted string to the current result
|
inlinestatic |
Write a formatted string to the current result
|
inlinestatic |
Write a formatted string to the current result
|
inlinestatic |
Write a line terminator to the current result
Referenced by NUnit.ConsoleRunner.Tests.ConsoleOutputTests.OneTimeSetUp(), NUnit.ConsoleRunner.Tests.ConsoleOutputTests.OneTimeTearDown(), NUnit.ConsoleRunner.Tests.ConsoleOutputTests.SetUp(), NUnit.ConsoleRunner.Tests.ConsoleOutputTests.TearDown(), NUnit.ConsoleRunner.Tests.ConsoleOutputTests.Test(), NUnit.Framework.Tests.TestContextTests.TestContextWriteLine_WritesToResult(), and NUnit.Framework.Internal.TestResultOutputTests.WriteToTestContext().
|
inlinestatic |
Write the string representation of a boolean value to the current result followed by a line terminator
|
inlinestatic |
Write a char to the current result followed by a line terminator
|
inlinestatic |
Write a char array to the current result followed by a line terminator
|
inlinestatic |
Write the string representation of a double to the current result followed by a line terminator
|
inlinestatic |
Write the string representation of an Int32 value to the current result followed by a line terminator
|
inlinestatic |
Write the string representation of an Int64 value to the current result followed by a line terminator
|
inlinestatic |
Write the string representation of a decimal value to the current result followed by a line terminator
|
inlinestatic |
Write the string representation of an object to the current result followed by a line terminator
|
inlinestatic |
Write the string representation of a Single value to the current result followed by a line terminator
|
inlinestatic |
Write a string to the current result followed by a line terminator
|
inlinestatic |
Write the string representation of a UInt32 value to the current result followed by a line terminator
|
inlinestatic |
Write the string representation of a UInt64 value to the current result followed by a line terminator
|
inlinestatic |
Write a formatted string to the current result followed by a line terminator
|
inlinestatic |
Write a formatted string to the current result followed by a line terminator
|
inlinestatic |
Write a formatted string to the current result followed by a line terminator
|
inlinestatic |
Write a formatted string to the current result followed by a line terminator
|
private |
|
private |
|
private |
|
staticget |
Get the current test context. This is created as needed. The user may save the context for use within a test, but it should not be used outside the test for which it is created.
Referenced by NUnit.Engine.Services.Tests.DriverServiceTests.CorrectDriverIsUsed(), NUnit.Engine.Drivers.Tests.NUnit3FrameworkDriverTests.CreateDriver(), NUnit.Framework.Api.TestAssemblyRunnerTests.CreateRunner(), NUnit.Framework.Tests.Attributes.TestExpectedResult.ExpectedResultDoesNotBlockApplyToTestAttributes(), NUnit.Engine.Services.Tests.TestFilteringTests.LoadAssembly(), NUnit.TestData.TestContextData.TestTestContextInOneTimeTearDown.OneTimeTearDown(), NUnit.Framework.Tests.TestContextOneTimeTearDownTests.OneTimeTearDown(), NUnit.Engine.Services.Tests.DomainManagerStaticTests.ProperConfigFileIsUsed(), NUnit.TestData.TestContextData.TestStateRecordingFixture.SetUp(), NUnit.TestData.TestContextData.TestStateRecordingFixture.TearDown(), NUnit.TestData.TestContextData.TestTestContextInTearDown.TearDown(), NUnit.Framework.Tests.TestContextTearDownTests.TearDown(), NUnit.Framework.Tests.TestContextTests.TestCanAccessItsOwnFullName(), NUnit.Framework.Tests.TestContextTests.TestCanAccessItsOwnId(), NUnit.Framework.Tests.TestContextTests.TestCanAccessItsOwnMethodName(), NUnit.Framework.Tests.TestContextTests.TestCanAccessItsOwnName(), NUnit.Framework.Tests.TestContextTests.TestCanAccessItsOwnProperties(), NUnit.Framework.Tests.TestContextTests.TestCanAccessWorkDirectory(), NUnit.Framework.Tests.TestContextTests.TestCaseCanAccessItsOwnFullName(), NUnit.Framework.Tests.TestContextTests.TestCaseCanAccessItsOwnMethodName(), NUnit.Framework.Tests.TestContextTests.TestCaseCanAccessItsOwnName(), NUnit.Framework.Tests.TestContextTests.TestContextTests(), and NUnit.TestData.TestContextData.TestStateRecordingFixture.TheTest().
|
staticget |
Gets a TextWriter that will send output to the current test result.
Referenced by NUnit.Framework.Tests.TestContextTests.TestContextOut_WritesToResult().
|
get |
Get a representation of the current test.
Referenced by NUnit.Framework.Tests.Attributes.TestExpectedResult.ExpectedResultDoesNotBlockApplyToTestAttributes(), NUnit.Framework.Tests.TestContextOneTimeTearDownTests.OneTimeTearDown(), NUnit.Framework.Tests.TestContextTearDownTests.TearDown(), NUnit.Framework.Tests.TestContextTests.TestCanAccessItsOwnFullName(), NUnit.Framework.Tests.TestContextTests.TestCanAccessItsOwnId(), NUnit.Framework.Tests.TestContextTests.TestCanAccessItsOwnMethodName(), NUnit.Framework.Tests.TestContextTests.TestCanAccessItsOwnName(), NUnit.Framework.Tests.TestContextTests.TestCanAccessItsOwnProperties(), NUnit.Framework.Tests.TestContextTests.TestCaseCanAccessItsOwnFullName(), NUnit.Framework.Tests.TestContextTests.TestCaseCanAccessItsOwnMethodName(), NUnit.Framework.Tests.TestContextTests.TestCaseCanAccessItsOwnName(), and NUnit.Framework.Tests.TestContextTests.TestContextTests().
|
get |
Gets a Representation of the TestResult for the current test.
Referenced by NUnit.TestData.TestContextData.TestTestContextInOneTimeTearDown.OneTimeTearDown(), NUnit.Framework.Tests.TestContextOneTimeTearDownTests.OneTimeTearDown(), NUnit.TestData.TestContextData.TestStateRecordingFixture.SetUp(), NUnit.TestData.TestContextData.TestStateRecordingFixture.TearDown(), NUnit.TestData.TestContextData.TestTestContextInTearDown.TearDown(), NUnit.Framework.Tests.TestContextTearDownTests.TearDown(), and NUnit.TestData.TestContextData.TestStateRecordingFixture.TheTest().
|
get |
Gets the directory containing the current test assembly.
Referenced by NUnit.Engine.Services.Tests.DriverServiceTests.CorrectDriverIsUsed(), NUnit.Engine.Drivers.Tests.NUnit3FrameworkDriverTests.CreateDriver(), NUnit.Framework.Api.TestAssemblyRunnerTests.CreateRunner(), NUnit.Engine.Services.Tests.TestFilteringTests.LoadAssembly(), NUnit.Engine.Services.Tests.DomainManagerStaticTests.ProperConfigFileIsUsed(), NUnit.Framework.Tests.TestContextTearDownTests.TearDown(), and NUnit.Framework.Tests.TestContextTests.TestContextTests().
|
get |
Gets the directory to be used for outputting files created by this test run.
Referenced by NUnit.Framework.Tests.TestContextTearDownTests.TearDown(), NUnit.Framework.Tests.TestContextTests.TestCanAccessWorkDirectory(), and NUnit.Framework.Tests.TestContextTests.TestContextTests().
|
get |
Gets the random generator.
The random generator.