Release Notes: July 24, 2022
xUnit.net v2 2.4.2 Pre-Release (build 27)
Core framework
-
BUG: Type inference gets confused when one theory parameter is null
(xunit/xunit#2401)
-
BUG: Converting theory data failed when there were multiple
op_Implicit
and/or op_Explicit
methods that might qualify for conversion.
-
BUG: Fixed a deserialization issue with skipped theories
(xunit/visualstudio#266)
-
BUG: Fixed an issue with missing flow IDs when reporting results to TeamCity
(xunit/xunit#2397)
-
BUG: Fix Console colors concurrency handling
(xunit/xunit#2228)
Assertion library
- Added
Assert.Distinct
, which ensures that every item in a collection is distinct.
-
Updated
KeyValuePair<TKey,TValue>
argument formatting. Old format: [Key, Value]
New format: [Key] = Value
. We also stopped special-casing dictionaries (they're just printed
out as KeyValuePair
collections). This is most obviously visible in Assert.Equivalent
when dictionaries are missing entries (or contain extra entries in strict mode).
-
Updated
Assert.Equivalent
for KeyValuePair<TKey,TValue>
to use equivalence for
key vs. key and value vs. value. This is most obviously visible when testing for dictionary equivalence when
the key or value is a collection (now those are recursively called into Assert.Equivalent
, whereas
they were previously using simple equality tests).
-
BUG: When
Assert.Equal
failed, it was causing a second
enumeration, which could fail and/or have a significant performance penalty.