コード例 #1
0
 public override void OneTimeSetup()
 {
     _regularExpressionRequestInstanceType    = typeof(RegularExpressionRequest);
     _regularExpressionRequestInstanceFixture = this.Create <RegularExpressionRequest>(true);
     _regularExpressionRequestInstance        = _regularExpressionRequestInstanceFixture ?? this.Create <RegularExpressionRequest>(false);
     CurrentInstance = _regularExpressionRequestInstanceFixture;
     ConfigureIgnoringTests(); // Configure ignoring tests.
 }
コード例 #2
0
        public void AUT_RegularExpressionRequest_Constructor_Instantiation_With_Parameter_Test()
        {
            // Arrange
            var pattern = this.CreateType <string>();
            RegularExpressionRequest instance = null;
            Exception creationException       = null;

            // Act
            Action createAction = () => instance = new RegularExpressionRequest(pattern);

            creationException = ActionAnalyzer.GetActionException(createAction);

            // Assert
            instance.ShouldNotBeNull();
            _regularExpressionRequestInstance.ShouldNotBeNull();
            _regularExpressionRequestInstanceFixture.ShouldNotBeNull();
            Should.NotThrow(createAction);
        }