Closed ctolkien closed 6 years ago
Also, change the test from a [Fact]
to:
[Theory]
[MemberData(nameof(ValidData))]
public void GivenACollectionOfMedias_CompareTo_CorrectlySortsTheCollection(Media[] medias)
{
and make ValidData
something like...
public static IEnumerable<object[]> ValidData => new[]
{
new object[]
{
// Collection sorted.
},
new object[]
{
// Collection but unsorted.
}
};
Also, need some tests for an empty collection (is that considered a valid test?)
also tests for comparing things that are not the same. This checks for the ArgumentException
.
eg. Order vs a Cow or whatever.
Also, need some tests for an empty collection (is that considered a valid test?)
How would we test that? That it doesn't throw?
How would we test that? That it doesn't throw?
Because that's a valid scenario and whatever the correct solution is (under that scenario), needs to be 1) considered 2) tested.
Manually ended up adding in these changes (or similar) to #42 .