49 references to CreateScriptCompilation
Microsoft.CodeAnalysis.CSharp.Emit.UnitTests (8)
CodeGen\CodeGenAsyncTests.cs (3)
4542
var s0 = CSharpCompilation.
CreateScriptCompilation
("s0.dll", SyntaxFactory.ParseSyntaxTree(source0, options: TestOptions.Script), references);
4543
var s1 = CSharpCompilation.
CreateScriptCompilation
("s1.dll", SyntaxFactory.ParseSyntaxTree(source1, options: TestOptions.Script), references, previousScriptCompilation: s0);
4553
var s0 = CSharpCompilation.
CreateScriptCompilation
("s0.dll", SyntaxFactory.ParseSyntaxTree(source0, options: TestOptions.Script), references);
CodeGen\CodeGenScriptTests.cs (1)
553
var s0 = CSharpCompilation.
CreateScriptCompilation
(
CodeGen\GotoTest.cs (4)
1000
var s0 = CSharpCompilation.
CreateScriptCompilation
("s0.dll", SyntaxFactory.ParseSyntaxTree(source0, options: TestOptions.Script), references);
1002
var s1 = CSharpCompilation.
CreateScriptCompilation
("s1.dll", SyntaxFactory.ParseSyntaxTree(source1, options: TestOptions.Script), references, previousScriptCompilation: s0);
1111
var s0 = CSharpCompilation.
CreateScriptCompilation
("s0.dll", SyntaxFactory.ParseSyntaxTree(source0, options: TestOptions.Script), references);
1113
var s1 = CSharpCompilation.
CreateScriptCompilation
("s1.dll", SyntaxFactory.ParseSyntaxTree(source1, options: TestOptions.Script), references, previousScriptCompilation: s0);
Microsoft.CodeAnalysis.CSharp.Scripting (1)
CSharpScriptCompiler.cs (1)
52
var compilation = CSharpCompilation.
CreateScriptCompilation
(
Microsoft.CodeAnalysis.CSharp.Semantic.UnitTests (4)
Semantics\BindingAsyncTests.cs (1)
3161
var submission = CSharpCompilation.
CreateScriptCompilation
(
Semantics\ScriptSemanticsTests.cs (1)
298
var submission = CSharpCompilation.
CreateScriptCompilation
("test", syntaxTree: SyntaxFactory.ParseSyntaxTree("1", options: TestOptions.Script), returnType: typeof(int));
Semantics\SwitchTests.cs (1)
2417
var submission = CSharpCompilation.
CreateScriptCompilation
(
Semantics\SyntaxTreeRootTests.cs (1)
63
Assert.Throws<ArgumentException>(() => CSharpCompilation.
CreateScriptCompilation
("Wah").AddSyntaxTrees(arbitraryTree));
Microsoft.CodeAnalysis.CSharp.Symbol.UnitTests (32)
Compilation\CompilationAPITests.cs (27)
1739
var firstCompilation = CSharpCompilation.
CreateScriptCompilation
(
1747
var secondCompilation = CSharpCompilation.
CreateScriptCompilation
(
1810
var compilation = CSharpCompilation.
CreateScriptCompilation
("sub",
1834
var compilation = CSharpCompilation.
CreateScriptCompilation
("sub",
2136
var c1 = CSharpCompilation.
CreateScriptCompilation
("c1");
2400
Assert.Throws<ArgumentException>(() => CSharpCompilation.
CreateScriptCompilation
("a", returnType: genericParameter));
2401
Assert.Throws<ArgumentException>(() => CSharpCompilation.
CreateScriptCompilation
("a", returnType: open));
2402
Assert.Throws<ArgumentException>(() => CSharpCompilation.
CreateScriptCompilation
("a", returnType: typeof(void)));
2403
Assert.Throws<ArgumentException>(() => CSharpCompilation.
CreateScriptCompilation
("a", returnType: byref));
2405
Assert.Throws<ArgumentException>(() => CSharpCompilation.
CreateScriptCompilation
("a", globalsType: genericParameter));
2406
Assert.Throws<ArgumentException>(() => CSharpCompilation.
CreateScriptCompilation
("a", globalsType: open));
2407
Assert.Throws<ArgumentException>(() => CSharpCompilation.
CreateScriptCompilation
("a", globalsType: typeof(void)));
2408
Assert.Throws<ArgumentException>(() => CSharpCompilation.
CreateScriptCompilation
("a", globalsType: typeof(int)));
2409
Assert.Throws<ArgumentException>(() => CSharpCompilation.
CreateScriptCompilation
("a", globalsType: ptr));
2410
Assert.Throws<ArgumentException>(() => CSharpCompilation.
CreateScriptCompilation
("a", globalsType: byref));
2412
var s0 = CSharpCompilation.
CreateScriptCompilation
("a0", globalsType: typeof(List<int>));
2413
Assert.Throws<ArgumentException>(() => CSharpCompilation.
CreateScriptCompilation
("a1", previousScriptCompilation: s0, globalsType: typeof(List<bool>)));
2416
Assert.Throws<ArgumentException>(() => CSharpCompilation.
CreateScriptCompilation
("a", options: TestOptions.ReleaseExe));
2417
Assert.Throws<ArgumentException>(() => CSharpCompilation.
CreateScriptCompilation
("a", options: TestOptions.ReleaseDll.WithOutputKind(OutputKind.NetModule)));
2418
Assert.Throws<ArgumentException>(() => CSharpCompilation.
CreateScriptCompilation
("a", options: TestOptions.ReleaseDll.WithOutputKind(OutputKind.WindowsRuntimeMetadata)));
2419
Assert.Throws<ArgumentException>(() => CSharpCompilation.
CreateScriptCompilation
("a", options: TestOptions.ReleaseDll.WithOutputKind(OutputKind.WindowsRuntimeApplication)));
2420
Assert.Throws<ArgumentException>(() => CSharpCompilation.
CreateScriptCompilation
("a", options: TestOptions.ReleaseDll.WithOutputKind(OutputKind.WindowsApplication)));
2421
Assert.Throws<ArgumentException>(() => CSharpCompilation.
CreateScriptCompilation
("a", options: TestOptions.ReleaseDll.WithCryptoKeyContainer("goo")));
2422
Assert.Throws<ArgumentException>(() => CSharpCompilation.
CreateScriptCompilation
("a", options: TestOptions.ReleaseDll.WithCryptoKeyFile("goo.snk")));
2423
Assert.Throws<ArgumentException>(() => CSharpCompilation.
CreateScriptCompilation
("a", options: TestOptions.ReleaseDll.WithDelaySign(true)));
2424
Assert.Throws<ArgumentException>(() => CSharpCompilation.
CreateScriptCompilation
("a", options: TestOptions.ReleaseDll.WithDelaySign(false)));
2430
Assert.False(CSharpCompilation.
CreateScriptCompilation
("sub").HasSubmissionResult());
Compilation\GetUnusedImportDirectivesTests.cs (1)
390
var comp = CSharpCompilation.
CreateScriptCompilation
("sub1", tree, new[] { MscorlibRef_v4_0_30316_17626 });
Symbols\ExtensionMethodTests.cs (2)
3818
var s0 = CSharpCompilation.
CreateScriptCompilation
(
3824
var s1 = CSharpCompilation.
CreateScriptCompilation
(
Symbols\Source\ExternAliasTests.cs (1)
110
var comp = CSharpCompilation.
CreateScriptCompilation
(
Symbols\SymbolErrorTests.cs (1)
20480
var submission = CSharpCompilation.
CreateScriptCompilation
("s0.dll", SyntaxFactory.ParseSyntaxTree(source, options: TestOptions.Script), new[] { MscorlibRef_v4_0_30316_17626, SystemCoreRef });
Microsoft.CodeAnalysis.CSharp.Test.Utilities (2)
CSharpTestBase.cs (2)
1462
Func<CSharpCompilation> createCompilationLambda = () => CSharpCompilation.
CreateScriptCompilation
(
1485
Func<CSharpCompilation> createCompilationLambda = () => CSharpCompilation.
CreateScriptCompilation
(
Microsoft.CodeAnalysis.CSharp.Workspaces (1)
Workspace\LanguageServices\CSharpCompilationFactoryService.cs (1)
35
return CSharpCompilation.
CreateScriptCompilation
(
Microsoft.CodeAnalysis.Workspaces.UnitTests (1)
Host\LanguageServices\TestCSharpCompilationFactoryServiceWithIncrementalGeneratorTracking.cs (1)
37
return CSharpCompilation.
CreateScriptCompilation
(