GisterSpecs.MockGitHubSender.FailWith C# (CSharp) Method

FailWith() public method

public FailWith ( string statusDescription ) : void
statusDescription string
return void
        public void FailWith(string statusDescription)
        {
            failureStatusDescription = statusDescription;
        }

Usage Example

Example #1
0
        public void WillAllowUsToGetInvolvedWhenCredentialsAreBad()
        {
            var sender = new MockGitHubSender();
            sender.FailWith("Blah");

            var uploads = new UploadsGists();
            uploads.GitHubSender = sender;

            var didTellUs = false;
            uploads.CredentialsAreBad = () => didTellUs = true;

            uploads.Upload("asdf", "asdF");

            didTellUs.Should().Be.True();
        }
All Usage Examples Of GisterSpecs.MockGitHubSender::FailWith