Fix nullability of AsEnumerable return type

This commit is contained in:
Oliver Booth 2022-04-24 10:29:04 +01:00
parent e2a496face
commit 199b82b9a6
No known key found for this signature in database
GPG Key ID: 32A00B35503AF634
1 changed files with 3 additions and 3 deletions

View File

@ -5,7 +5,7 @@ using X10D.Core;
namespace X10D.Tests.Core;
[TestClass]
public partial class EnumerableTests
public class EnumerableTests
{
[TestMethod]
[DataRow(1)]
@ -13,7 +13,7 @@ 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));