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

Use the Xunit assert library instead of CoreCLRTestLibrary for most asserts #61226

Merged
merged 5 commits into from
Nov 6, 2021

Commits on Nov 4, 2021

  1. Use the Xunit assert library instead of CoreCLRTestLibrary for most a…

    …sserts.
    
    Asserts not provided by Xunit are provided by an AssertExtensions class.
    
    Tests that reference System.Private.Corelib directly will use a polyfill implementation based off the old CoreCLRTestLibrary asserts.
    
    All assert methods provided by CoreCLRTestLibrary have been changed to follow Xunit conventions.
    jkoritzinsky committed Nov 4, 2021
    Configuration menu
    Copy the full SHA
    2385e3d View commit details
    Browse the repository at this point in the history
  2. Update src/tests/Common/Assert.cs

    Co-authored-by: Aaron Robinson <arobins@microsoft.com>
    jkoritzinsky and AaronRobinsonMSFT committed Nov 4, 2021
    Configuration menu
    Copy the full SHA
    2592739 View commit details
    Browse the repository at this point in the history
  3. Update src/tests/Common/Assert.cs

    Co-authored-by: Aaron Robinson <arobins@microsoft.com>
    jkoritzinsky and AaronRobinsonMSFT committed Nov 4, 2021
    Configuration menu
    Copy the full SHA
    f5db76b View commit details
    Browse the repository at this point in the history

Commits on Nov 5, 2021

  1. Fix ThrowsWithInnerException and CollectionEqual

    CollectionEqual ended up in infinite recursion as the array variant
    no longer accepts the third string argument (there's no use for it
    as Assert.Equal no longer supports it; after all, a single test was
    using it) so that the enumerable variant ended up calling itself
    instead of the array variant. I have removed the message string
    and I deleted it from the one ResolveUnmanagedDllTests source.
    
    In ThrowsWithInnerException there was a typo, there should be
    "is TInner" in the inner exception check, not "is T".
    
    Thanks
    
    Tomas
    trylek committed Nov 5, 2021
    Configuration menu
    Copy the full SHA
    c183252 View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    abeccc5 View commit details
    Browse the repository at this point in the history