Skip to content

Add xUnit analyzers and take fixer suggestions (1 of 5): Common to System.Web.Cors.Test #88

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

Closed
wants to merge 1 commit into from

Conversation

dougbu
Copy link
Contributor

@dougbu dougbu commented Oct 25, 2017

  • part of Update to latest tooling #65
  • do not use xunit.core package in Microsoft.TestCommon
  • improve TestData behavior when tests sharing dataset properties run in parallel

Manual changes:

  • use Assert.IsAssignableFrom<T>(...), Assert.IsType<T>(...) and Assert.Single(...) return values
  • work around xUnit1013, Public method should be marked as test
    • move duplicated [Theory] and [TestDataSet(...)] attributes down to abstract methods
    • add suppression due to xnuit/xunit#1466
  • work around xUnit1026, [Theory] method doesn't use all parameters
    • add new data sets or GC.KeepAlive(...)
  • reset OAuthWebSecurity.OAuthDataProvider after use in two tests

…stem.Web.Cors.Test

- part of #65
- do not use `xunit.core` package in Microsoft.TestCommon
- improve `TestData` behavior when tests sharing dataset properties run in parallel

ExceptionResultTests.ExecuteAsync_ReturnsCorrectResponse_WhenContentNegotiationSucceedsAndIncludeErrorDetailIsTrue

Manual changes:
- use `Assert.IsAssignableFrom<T>(...)`, `Assert.IsType<T>(...)` and `Assert.Single(...)` return values
- work around xUnit1013, Public method should be marked as test
  - move duplicated `[Theory]` and `[TestDataSet(...)]` attributes down to `abstract` methods
  - add suppression due to xnuit/xunit#1466
- work around xUnit1026, `[Theory]` method doesn't use all parameters
  - add new data sets or `GC.KeepAlive(...)`
- reset `OAuthWebSecurity.OAuthDataProvider` after use in two tests
@dnfclas
Copy link

dnfclas commented Oct 25, 2017

@dougbu,
Thanks for having already signed the Contribution License Agreement. Your agreement was validated by .NET Foundation. We will now review your pull request.
Thanks,
.NET Foundation Pull Request Bot

@dougbu
Copy link
Contributor Author

dougbu commented Oct 25, 2017

74fcc24

@dougbu dougbu closed this Oct 25, 2017
@dougbu dougbu deleted the dougbu/add.analyzers.1 branch October 25, 2017 22:21
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants