mirror of
https://github.com/oliverbooth/X10D
synced 2024-11-22 19:28:48 +00:00
Fix nullability of AsEnumerable return type
This commit is contained in:
parent
e2a496face
commit
199b82b9a6
@ -5,7 +5,7 @@ using X10D.Core;
|
||||
namespace X10D.Tests.Core;
|
||||
|
||||
[TestClass]
|
||||
public partial class EnumerableTests
|
||||
public class EnumerableTests
|
||||
{
|
||||
[TestMethod]
|
||||
[DataRow(1)]
|
||||
@ -13,12 +13,12 @@ public partial class EnumerableTests
|
||||
[DataRow(true)]
|
||||
public void AsEnumerable(object o)
|
||||
{
|
||||
IEnumerable<object> array = o.AsEnumerable().ToArray(); // prevent multiple enumeration of IEnumerable
|
||||
IEnumerable<object?> array = o.AsEnumerable().ToArray(); // prevent multiple enumeration of IEnumerable
|
||||
Assert.IsNotNull(array);
|
||||
Assert.IsTrue(array.Count() == 1);
|
||||
Assert.AreEqual(o, array.ElementAt(0));
|
||||
}
|
||||
|
||||
|
||||
[TestMethod]
|
||||
[DataRow(1, 2, 3, 4, 5, 6, 7, 8, 9, 10)]
|
||||
public void Shuffled(params int[] source)
|
||||
|
Loading…
Reference in New Issue
Block a user