public void CheckEventLogEntry() { TestStepBuilder tsb = new TestStepBuilder("BizUnit.EventLogCheckStep", null); object[] args = new object[1]; args[0] = "Application"; tsb.SetProperty("EventLog", args); args = new object[1]; args[0] = "VAA FFP"; tsb.SetProperty("Source", args); args = new object[1]; args[0] = "Error"; tsb.SetProperty("EventType", args); args = new object[1]; args[0] = 2028; tsb.SetProperty("EventId", args); args = new object[1]; args[0] = "FieldValue: '3'"; tsb.SetProperty("ValidationRegexs", args); BizUnitTestCase testCase = new BizUnitTestCase("FileCreateStepTest"); testCase.AddTestStep(tsb, TestStage.Execution); BizUnit bizUnit = new BizUnit(testCase); bizUnit.RunTest(); }
internal BizUnitTestStepWrapper(TestStepBuilder testStepBuilder, bool runConcurrently, bool failOnError) { ArgumentValidation.CheckForNullReference(testStepBuilder, "testStepBuilder"); _testStepBuilder = testStepBuilder; RunConcurrently = runConcurrently; _failOnError = failOnError; TypeName = testStepBuilder.TestStepOM.GetType().ToString(); }
internal BizUnitTestStepWrapper(ITestStepOM testStep, bool runConcurrently, bool failOnError) { ArgumentValidation.CheckForNullReference(testStep, "testStep"); _testStepBuilder = new TestStepBuilder(testStep); _runConcurrently = runConcurrently; _failOnError = failOnError; _typeName = testStep.GetType().ToString(); }
internal BizUnitTestStepWrapper(TestStepBuilder testStepBuilder, bool runConcurrently, bool failOnError) { ArgumentValidation.CheckForNullReference(testStepBuilder, "testStepBuilder"); _testStepBuilder = testStepBuilder; RunConcurrently = runConcurrently; FailOnError = failOnError; TypeName = testStepBuilder.TestStepOM.GetType().ToString(); }
/// <summary> /// Used to add a test step to a test case at a specific stage of the test. /// </summary> /// /// <param name='testStep'>The test step to add to the test case, /// creation of the test step is delegated to the TestStepBuilder</param> /// <param name='stage'>The stage of the test case in which to add the test step</param> public void AddTestStep(TestStepBuilder testStep, TestStage stage) { ArgumentValidation.CheckForNullReference(testStep, "testStep"); AddTestStep(testStep, stage, false, true); }
/// <summary> /// Used to add a test step to a test case at a specific stage of the test. /// </summary> /// /// <param name='testStep'>The test step to add to the test case, /// creation of the test step is delegated to the TestStepBuilder</param> /// <param name='stage'>The stage of the test case in which to add the test step</param> /// <param name='runConcurrently'>Specifies whether the test step /// should run concurrently to other test steps. Defaults to false if not specified.</param> /// <param name='failOnError'>Specifies whether the entire test case /// should fail if this individual test step fails, defaults to true if not specified.</param> public void AddTestStep(TestStepBuilder testStep, TestStage stage, bool runConcurrently, bool failOnError) { ArgumentValidation.CheckForNullReference(testStep, "testStep"); AddTestStepInternal(new BizUnitTestStepWrapper(testStep, runConcurrently, failOnError), stage); }