Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Replace [ExpectedException] with Assert.Throws #35

Merged
merged 1 commit into from
Nov 14, 2016
Merged

Replace [ExpectedException] with Assert.Throws #35

merged 1 commit into from
Nov 14, 2016

Commits on Nov 13, 2016

  1. Replace [ExpectedException] with Assert.Throws

    As outlined in issue #34, unit tests relying on a `[ExpectedException]`
    attribute should be rewritten to use `Assert.Throws` instead:
    
     * `[ExpectedException]` is too coarse-grained and doesn't allow us to
       test only the Act stage in Arrange-Act-Assert. `Assert.Throws` does
       not suffer from this.
    
     * `[ExpectedException]` is no longer supported in NUnit version 3.
    
    This commit replaces all occurrences of the attribute with the more
    flexible `Assert.Throws`. In some cases, parts of the `TestDelegate`
    that belong to the Arrange stage are moved out of it.
    stakx committed Nov 13, 2016
    Configuration menu
    Copy the full SHA
    990d120 View commit details
    Browse the repository at this point in the history