58 references to ContinueWithAsync
Microsoft.CodeAnalysis.CSharp.Scripting.Desktop.UnitTests (32)
InteractiveSessionReferencesTests.cs (32)
49
var s1 = s0.
ContinueWithAsync
($"#r \"{typeof(Process).Assembly.Location}\"");
62
var s1 = s0.
ContinueWithAsync
(@"Process.GetCurrentProcess()", newOptions);
72
var s1 = s0.
ContinueWithAsync
($@"
205
var s2 = await s1.
ContinueWithAsync
(@"
513
var s1 = await s0.
ContinueWithAsync
($@"
631
var s1 = await s0.
ContinueWithAsync
($@"var l1 = new Lib1();");
632
var s2 = await s1.
ContinueWithAsync
($@"#r ""{file2.Path}""");
633
var s3 = await s2.
ContinueWithAsync
($@"var l2 = new Lib2();");
634
var s4 = await s3.
ContinueWithAsync
($@"l2.libBase.X");
689
var s1 = await s0.
ContinueWithAsync
($@"var l1 = new Lib1();");
690
var s2 = await s1.
ContinueWithAsync
($@"#r ""{file2.Path}""");
691
var s3 = await s2.
ContinueWithAsync
($@"var l2 = new Lib2();");
692
var s4 = await s3.
ContinueWithAsync
($@"l2.libBase.X");
755
var s1 = await s0.
ContinueWithAsync
($@"var l1 = new Lib1();");
756
var s2 = await s1.
ContinueWithAsync
($@"#r ""{file2.Path}""");
761
await s2.
ContinueWithAsync
($@"var l2 = new Lib2();");
823
var s1 = await s0.
ContinueWithAsync
($@"new Lib1().libBase.X");
824
var s2 = await s1.
ContinueWithAsync
($@"#r ""{file2.Path}""");
829
await s2.
ContinueWithAsync
($@"new Lib2().libBase.X");
891
var s1 = await s0.
ContinueWithAsync
($@"new Lib1().libBase.X");
892
var s2 = await s1.
ContinueWithAsync
($@"#r ""{file2.Path}""");
897
await s2.
ContinueWithAsync
($@"new Lib2().libBase.X");
959
var s1 = await s0.
ContinueWithAsync
($@"new Lib1().libBase.X");
960
var s2 = await s1.
ContinueWithAsync
($@"#r ""{file2.Path}""");
965
await s2.
ContinueWithAsync
($@"new Lib2().libBase.X");
1027
var s1 = await s0.
ContinueWithAsync
($@"var l1 = new Lib1().libBase.X;");
1028
var s2 = await s1.
ContinueWithAsync
($@"#r ""{file2.Path}""");
1033
await s2.
ContinueWithAsync
($@"var l2 = new Lib2().libBase.X;");
1095
var s1 = await s0.
ContinueWithAsync
($@"new Lib1().libBase.X");
1097
var s2 = await s1.
ContinueWithAsync
($@"#r ""{file2.Path}""");
1098
var s3 = await s2.
ContinueWithAsync
($@"new Lib2().libBase.X");
1121
await s0.
ContinueWithAsync
("c = new C()");
Microsoft.CodeAnalysis.CSharp.Scripting.UnitTests (23)
InteractiveSessionTests.cs (15)
624
Assert.Throws<CompilationErrorException>(() => s0.
ContinueWithAsync
("invalid$syntax").Result);
626
var s1 = await s0.
ContinueWithAsync
("x = 2; x = 10");
628
Assert.Throws<CompilationErrorException>(() => s1.
ContinueWithAsync
("invalid$syntax").Result);
629
Assert.Throws<CompilationErrorException>(() => s1.
ContinueWithAsync
("x = undefined_symbol").Result);
631
var s2 = await s1.
ContinueWithAsync
("int y = 2;");
635
var s3 = await s2.
ContinueWithAsync
("x + y");
1105
var s1 = await s0.
ContinueWithAsync
("F(async () => await Task.FromResult(4))");
1108
var s2 = await s1.
ContinueWithAsync
("G(5, async x => await Task.FromResult(x))");
1153
state = await state.
ContinueWithAsync
("x is (false, var y)");
1162
state = await state.
ContinueWithAsync
("x is long or int", options: options);
1164
state = await state.
ContinueWithAsync
("x is int and < 10", options: options);
1166
state = await state.
ContinueWithAsync
("x is (long or < 10L)", options: options);
1168
state = await state.
ContinueWithAsync
("x is not > 100", options: options);
2001
var state1 = await state0.
ContinueWithAsync
(@"
2017
var state4 = await state2.
ContinueWithAsync
(@"
ScriptTests.cs (8)
364
state = await state.
ContinueWithAsync
(submission);
426
var s3 = await s1.
ContinueWithAsync
("x");
459
var state2 = await state1.
ContinueWithAsync
("int M(int x) { return x * x; } M(5)");
464
var state3 = await state1.
ContinueWithAsync
("M(5)");
472
var state1 = await state0.
ContinueWithAsync
("System.Func<int, int, int> adder = Add;");
473
var state2 = await state1.
ContinueWithAsync
("adder(1, 1)");
481
var state1 = await state0.
ContinueWithAsync
("Id<int>.Get(1)");
489
var state1 = await state0.
ContinueWithAsync
("Id.Get<int>()(1)");
Microsoft.CodeAnalysis.Scripting.TestUtilities (3)
ScriptingTestHelpers.cs (3)
61
AssertCompilationError(() => state.Result.
ContinueWithAsync
(code).Wait(), expectedDiagnostics);
66
AssertCompilationError(() => state.Result.
ContinueWithAsync
(code).Wait(), expectedDiagnostics);
71
AssertCompilationError(() => state.
ContinueWithAsync
(code).Wait(), expectedDiagnostics);