}
}
+ [Test]
+ public void WhenAll_Empty ()
+ {
+ var tasks = new Task[0];
+
+ Task t = Task.WhenAll(tasks);
+
+ Assert.IsTrue(t.Wait(1000), "#1");
+ }
+
[Test]
public void WhenAll_WithNull ()
{
Assert.IsTrue (t.Wait (1000), "#2");
}
+ [Test]
+ public void WhenAllResult_Empty ()
+ {
+ var tasks = new Task<int>[0];
+
+ Task<int[]> t = Task.WhenAll(tasks);
+
+ Assert.IsTrue(t.Wait(1000), "#1");
+ Assert.IsNotNull(t.Result, "#2");
+ Assert.AreEqual(t.Result.Length, 0, "#3");
+ }
+
[Test]
public void WhenAllResult_WithNull ()
{