431 references to MscorlibRef
Microsoft.CodeAnalysis.CSharp.CommandLine.UnitTests (1)
CommandLineTests.cs (1)
7345var compilation = CSharpCompilation.Create("a.dll", references: new[] { MscorlibRef }, options: TestOptions.ReleaseDll);
Microsoft.CodeAnalysis.CSharp.Emit.UnitTests (123)
CodeGen\CodeGenTupleTest.cs (80)
4106references: new[] { MscorlibRef, ValueTupleRef, SystemRuntimeFacadeRef, SystemCoreRef }); 5788var comp = CSharpCompilation.Create("test", references: new[] { MscorlibRef }); // no ValueTuple 5814var comp = CSharpCompilation.Create("test", references: new[] { MscorlibRef, tupleComp.ToMetadataReference() }); 5851var comp = CSharpCompilation.Create("test", references: new[] { MscorlibRef, tupleComp.ToMetadataReference() }); 5868var comp = CSharpCompilation.Create("test", references: new[] { MscorlibRef, tupleComp.ToMetadataReference() }); 5903var comp = CSharpCompilation.Create("test", references: new[] { MscorlibRef, tupleComp.ToMetadataReference() }); 5938var comp = CSharpCompilation.Create("test", references: new[] { MscorlibRef, tupleComp.EmitToImageReference() }); 5946var comp = CSharpCompilation.Create("test", references: new[] { MscorlibRef }); // no ValueTuple 5967var comp = CSharpCompilation.Create("test", references: new[] { MscorlibRef }); // no ValueTuple 5986var comp = CSharpCompilation.Create("test", references: new[] { MscorlibRef }); // no ValueTuple 6005var comp = CSharpCompilation.Create("test", references: new[] { MscorlibRef }); // no ValueTuple 6023var comp = CSharpCompilation.Create("test", references: new[] { MscorlibRef }); // no ValueTuple 6049var comp = CSharpCompilation.Create("test", references: new[] { MscorlibRef, tupleComp.ToMetadataReference() }); 6075var comp = CSharpCompilation.Create("test", references: new[] { MscorlibRef }); // no ValueTuple 6100var comp = CSharpCompilation.Create("test", references: new[] { MscorlibRef }); // no ValueTuple 6125var comp = CSharpCompilation.Create("test", references: new[] { MscorlibRef }); // no ValueTuple 6151var comp = CSharpCompilation.Create("test", references: new[] { MscorlibRef }); // no ValueTuple 6184var comp = CSharpCompilation.Create("test", references: new[] { MscorlibRef, tupleComp.ToMetadataReference() }); 6208var comp = (Compilation)CSharpCompilation.Create("test", references: new[] { MscorlibRef, TestReferences.SymbolsTests.netModule.netModule1 }); 6268var comp = CSharpCompilation.Create("test", references: new[] { MscorlibRef }); 6290var comp = CSharpCompilation.Create("test", references: new[] { MscorlibRef }); 6313var comp = CSharpCompilation.Create("test", references: new[] { MscorlibRef }); 6330var comp = CSharpCompilation.Create("test", references: new[] { MscorlibRef }); 6338var comp = CSharpCompilation.Create("test", references: new[] { MscorlibRef }); // no ValueTuple 6362var comp = CSharpCompilation.Create("test", references: new[] { MscorlibRef, tupleComp.ToMetadataReference() }); 6381var comp = CSharpCompilation.Create("test", references: new[] { MscorlibRef, tupleComp.ToMetadataReference() }); 6411var comp = CSharpCompilation.Create("test", references: new[] { MscorlibRef }); // no ValueTuple 6427var comp = CSharpCompilation.Create("test", references: new[] { MscorlibRef }); // no ValueTuple 6443var comp = CSharpCompilation.Create("test", references: new[] { MscorlibRef }); // no ValueTuple 6458var comp = CSharpCompilation.Create("test", references: new[] { MscorlibRef }); // no ValueTuple 6478var comp = CSharpCompilation.Create("test", references: new[] { MscorlibRef }); // no ValueTuple 6498var comp = CSharpCompilation.Create("test", references: new[] { MscorlibRef }); // no ValueTuple 6519var comp = CSharpCompilation.Create("test", references: new[] { MscorlibRef }); // no ValueTuple 6541var comp = CSharpCompilation.Create("test", references: new[] { MscorlibRef, tupleComp.ToMetadataReference() }); 6558var comp = CSharpCompilation.Create("test", references: new[] { MscorlibRef }); 6583var comp = CSharpCompilation.Create("test", references: new[] { MscorlibRef }); 6933var comp = CSharpCompilation.Create("test", references: new[] { MscorlibRef }); 18841var comp = CSharpCompilation.Create("test", references: new[] { MscorlibRef, tupleComp.ToMetadataReference() }); 18859var comp = (Compilation)CSharpCompilation.Create("test", references: new[] { MscorlibRef, tupleComp.ToMetadataReference() }); 18879var comp = (Compilation)CSharpCompilation.Create("test", references: new[] { MscorlibRef, tupleComp.ToMetadataReference() }); 18902var comp = CSharpCompilation.Create("test", references: new[] { MscorlibRef, tupleComp.ToMetadataReference() }); 18919var comp = (Compilation)CSharpCompilation.Create("test", references: new[] { MscorlibRef, tupleComp.ToMetadataReference() }); 18945var comp = (Compilation)CSharpCompilation.Create("test", references: new[] { MscorlibRef, tupleComp1.ToMetadataReference(), tupleComp2.ToMetadataReference() }); 18970var comp = (Compilation)CSharpCompilation.Create("test", references: new[] { MscorlibRef, tupleComp1.ToMetadataReference(), tupleComp2.ToMetadataReference() }); 18995var comp = (Compilation)CSharpCompilation.Create("test", references: new[] { MscorlibRef, tupleComp1.ToMetadataReference(), tupleComp2.ToMetadataReference() }); 19021var comp = (Compilation)CSharpCompilation.Create("test", references: new[] { MscorlibRef, tupleComp1.ToMetadataReference(), tupleComp2.ToMetadataReference() }); 19137var comp = (Compilation)CSharpCompilation.Create("test", syntaxTrees: new[] { tree }, references: new[] { MscorlibRef, tupleComp1.ToMetadataReference() }); 19176var comp = (Compilation)CSharpCompilation.Create("test", syntaxTrees: new[] { tree }, references: new[] { MscorlibRef, tupleComp1.ToMetadataReference() }); 25689references: new[] { MscorlibRef, ValueTupleRef, SystemRuntimeFacadeRef }); 25734references: new[] { MscorlibRef, ValueTupleRef, SystemRuntimeFacadeRef }); 25760references: new[] { MscorlibRef, ValueTupleRef, SystemRuntimeFacadeRef }); 25805references: new[] { MscorlibRef, ValueTupleRef, SystemRuntimeFacadeRef }); 25831references: new[] { MscorlibRef, ValueTupleRef, SystemRuntimeFacadeRef }); 25870references: new[] { MscorlibRef, ValueTupleRef, SystemRuntimeFacadeRef }); 25903references: new[] { MscorlibRef, ValueTupleRef, SystemRuntimeFacadeRef }); 26669var vtLib = CreateEmptyCompilation(trivial2uple + tupleattributes_cs, references: new[] { MscorlibRef }, assemblyName: "vt"); 26681var lib = CreateEmptyCompilation(lib_cs, references: new[] { MscorlibRef, vtLib.EmitToImageReference() }); 26692var comp = CreateEmptyCompilation(client_cs, references: new[] { MscorlibRef, lib.EmitToImageReference() }); // missing reference to vt 26696var compWithMetadataReference = CreateEmptyCompilation(client_cs, references: new[] { MscorlibRef, lib.ToMetadataReference() }); // missing reference to vt 26700var fakeVtLib = CreateEmptyCompilation("", references: new[] { MscorlibRef }, assemblyName: "vt"); 26701var compWithFakeVt = CreateEmptyCompilation(client_cs, references: new[] { MscorlibRef, lib.EmitToImageReference(), fakeVtLib.EmitToImageReference() }); // reference to fake vt 26716var comp2 = CreateEmptyCompilation(client2_cs, references: new[] { MscorlibRef, lib.EmitToImageReference() }); // missing reference to vt 26727var comp2WithFakeVt = CreateEmptyCompilation(client2_cs, references: new[] { MscorlibRef, lib.EmitToImageReference(), fakeVtLib.EmitToImageReference() }); // reference to fake vt 26771var vtLib = CreateEmptyCompilation(tuplelib_cs + tupleattributes_cs, references: new[] { MscorlibRef }, assemblyName: "vt"); 26783var lib = CreateEmptyCompilation(lib_cs, references: new[] { MscorlibRef, vtLib.EmitToImageReference() }); 26797var fakeVtLib = CreateEmptyCompilation("", references: new[] { MscorlibRef }, assemblyName: "vt"); 26798var comp = CreateEmptyCompilation(client2_cs, references: new[] { MscorlibRef, lib.EmitToImageReference() }); // missing reference to vt 26809var compWithFakeVt = CreateEmptyCompilation(client2_cs, references: new[] { MscorlibRef, lib.EmitToImageReference(), fakeVtLib.EmitToImageReference() }); // reference to fake vt 26835var containerLib = CreateEmptyCompilation("public class Container<T> { }", references: new[] { MscorlibRef }, assemblyName: "container"); 26847var lib = CreateEmptyCompilation(lib_cs + tuplelib_cs + tupleattributes_cs, references: new[] { MscorlibRef, containerLib.EmitToImageReference() }); 26858var comp = CreateEmptyCompilation(client_cs, references: new[] { MscorlibRef, lib.EmitToImageReference() }); // missing reference to container 26862var compWithMetadataReference = CreateEmptyCompilation(client_cs, references: new[] { MscorlibRef, lib.ToMetadataReference() }); // missing reference to container 26866var fakeContainerLib = CreateEmptyCompilation("", references: new[] { MscorlibRef }, assemblyName: "container"); 26867var compWithFakeContainer = CreateEmptyCompilation(client_cs, references: new[] { MscorlibRef, lib.EmitToImageReference(), fakeContainerLib.EmitToImageReference() }); // reference to fake container 26910var containerLib = CreateEmptyCompilation("public class Container<T> { public class Contained<U> { } }", references: new[] { MscorlibRef }, assemblyName: "container"); 26922var lib = CreateEmptyCompilation(lib_cs + tuplelib_cs + tupleattributes_cs, references: new[] { MscorlibRef, containerLib.EmitToImageReference() }); 26933var comp = CreateEmptyCompilation(client_cs, references: new[] { MscorlibRef, lib.EmitToImageReference() }); // missing reference to container 26937var compWithMetadataReference = CreateEmptyCompilation(client_cs, references: new[] { MscorlibRef, lib.ToMetadataReference() }); // missing reference to container 26941var fakeContainerLib = CreateEmptyCompilation("", references: new[] { MscorlibRef }, assemblyName: "container"); 26942var compWithFakeContainer = CreateEmptyCompilation(client_cs, references: new[] { MscorlibRef, lib.EmitToImageReference(), fakeContainerLib.EmitToImageReference() }); // reference to fake container
Emit\CompilationEmitTests.cs (34)
897var compWithMetadata = CreateEmptyCompilation("", references: new[] { MscorlibRef, metadataRef }, 1807referencedAssemblies: new[] { MscorlibRef }); 1816referencedAssemblies: new[] { MscorlibRef, image1 }); 1826referencedAssemblies: new[] { MscorlibRef, image1, image2 }); 2124CSharpCompilation comp = CreateEmptyCompilation(source, references: new[] { MscorlibRef }, 2133var compWithReal = CreateEmptyCompilation("", parseOptions: parseOptions, references: new[] { MscorlibRef, realImage }, 2164var compWithReal2 = CreateEmptyCompilation("", parseOptions: parseOptions, references: new[] { MscorlibRef, realImage2 }, 2192var compWithMetadata = CreateEmptyCompilation("", parseOptions: parseOptions, references: new[] { MscorlibRef, metadataImage }, 2221var compWithRef = CreateEmptyCompilation("", parseOptions: parseOptions, references: new[] { MscorlibRef, refImage }, 2263CSharpCompilation comp = CreateEmptyCompilation(source, parseOptions: parseOptions, references: new[] { MscorlibRef }, 2270var compWithReal = CreateEmptyCompilation("", parseOptions: parseOptions, references: new[] { MscorlibRef, realImage }, 2280var compWithMetadata = CreateEmptyCompilation("", parseOptions: parseOptions, references: new[] { MscorlibRef, metadataImage }, 2292var compWithRef = CreateEmptyCompilation("", parseOptions: parseOptions, references: new[] { MscorlibRef, refImage }, 2330CSharpCompilation comp = CreateEmptyCompilation(source, parseOptions: parseOptions, references: new[] { MscorlibRef }, 2337var compWithReal = CreateEmptyCompilation("", parseOptions: parseOptions, references: new[] { MscorlibRef, realImage }, 2347var compWithMetadata = CreateEmptyCompilation("", parseOptions: parseOptions, references: new[] { MscorlibRef, metadataImage }, 2359var compWithRef = CreateEmptyCompilation("", parseOptions: parseOptions, references: new[] { MscorlibRef, refImage }, 2397CSharpCompilation comp = CreateEmptyCompilation(source, parseOptions: parseOptions, references: new[] { MscorlibRef }, 2404var compWithReal = CreateEmptyCompilation("", parseOptions: parseOptions, references: new[] { MscorlibRef, realImage }, 2414var compWithMetadata = CreateEmptyCompilation("", parseOptions: parseOptions, references: new[] { MscorlibRef, metadataImage }, 2426var compWithRef = CreateEmptyCompilation("", parseOptions: parseOptions, references: new[] { MscorlibRef, refImage }, 2457CSharpCompilation comp = CreateEmptyCompilation(source, parseOptions: parseOptions, references: new[] { MscorlibRef }, 2465var compWithRef = CreateEmptyCompilation("", parseOptions: parseOptions, references: new[] { MscorlibRef, refImage }, 2502CSharpCompilation comp = CreateEmptyCompilation(source, parseOptions: parseOptions, references: new[] { MscorlibRef }, 2510var compWithRef = CreateEmptyCompilation("", parseOptions: parseOptions, references: new[] { MscorlibRef, refImage }, 2524CSharpCompilation comp = CreateEmptyCompilation("", references: new[] { MscorlibRef }, 2538CSharpCompilation comp = CreateEmptyCompilation("", references: new[] { MscorlibRef }, 2552CSharpCompilation comp = CreateEmptyCompilation("", references: new[] { MscorlibRef }, 2567CSharpCompilation comp = CreateEmptyCompilation("", references: new[] { MscorlibRef }, 2580CSharpCompilation comp = CreateEmptyCompilation("", references: new[] { MscorlibRef }, 2594CSharpCompilation comp = CreateEmptyCompilation("", references: new[] { MscorlibRef }, 2607CSharpCompilation comp = CreateEmptyCompilation("", references: new[] { MscorlibRef }, 2633CSharpCompilation comp = CreateEmptyCompilation("", references: new[] { MscorlibRef }, 2653CSharpCompilation comp = CreateEmptyCompilation(source, references: new[] { MscorlibRef },
Emit\DeterministicTests.cs (4)
38references: new[] { MscorlibRef }, 55var compilation = CreateEmptyCompilation(source, assemblyName: "DeterminismTest", references: new[] { MscorlibRef, SystemCoreRef, CSharpRef }, options: options); 76assemblyName: "DeterminismTest", references: new[] { MscorlibRef }, 81references: new[] { MscorlibRef },
Emit\ResourceTests.cs (5)
290var c1 = CSharpCompilation.Create("goo", references: new[] { MscorlibRef }, options: TestOptions.ReleaseDll); 454new[] { MscorlibRef }, 498new[] { MscorlibRef }, 547new[] { MscorlibRef }, 604new[] { MscorlibRef },
Microsoft.CodeAnalysis.CSharp.Emit2.UnitTests (19)
Emit\EditAndContinue\AssemblyReferencesTests.cs (14)
43var references = new[] { SystemWindowsFormsRef, MscorlibRef, SystemCoreRef }; 141var md1 = AssemblyMetadata.CreateFromStream(CreateEmptyCompilation(srcPE, parseOptions: parseOptions, references: new[] { MscorlibRef, SystemRef }).EmitToStream()); 143var compilation0 = CreateEmptyCompilation(src1, parseOptions: parseOptions, references: new[] { MscorlibRef }); 219var compilation0 = CreateEmptyCompilation(src0, new[] { MscorlibRef, lib0.ToMetadataReference() }, assemblyName: "C", options: TestOptions.DebugDll); 220var compilation1 = compilation0.WithSource(src1).WithReferences(new[] { MscorlibRef, lib1.ToMetadataReference() }); 221var compilation2 = compilation1.WithSource(src2).WithReferences(new[] { MscorlibRef, lib2.ToMetadataReference() }); 323var compilation0 = CreateEmptyCompilation(src0, new[] { MscorlibRef, lib0.ToMetadataReference() }, assemblyName: "C", options: TestOptions.DebugDll); 324var compilation1 = compilation0.WithSource(src1).WithReferences(new[] { MscorlibRef, lib1.ToMetadataReference() }); 325var compilation2 = compilation1.WithSource(src2).WithReferences(new[] { MscorlibRef, lib2.ToMetadataReference() }); 406var compilation0 = CreateEmptyCompilation(src0, new[] { MscorlibRef, lib0.EmitToImageReference() }, assemblyName: "C", options: TestOptions.DebugDll); 407var compilation1 = compilation0.WithSource(src1).WithReferences(new[] { MscorlibRef, lib1.EmitToImageReference() }); 408var compilation2 = compilation1.WithSource(src2).WithReferences(new[] { MscorlibRef, lib2.EmitToImageReference() }); 490var compilation0 = CreateEmptyCompilation(src0, new[] { MscorlibRef, ref01, ref11 }, assemblyName: "C", options: TestOptions.DebugDll); 491var compilation1 = compilation0.WithSource(src1).WithReferences(new[] { MscorlibRef, ref02, ref12 });
Emit\EditAndContinue\SymbolMatcherTests.cs (1)
308var compilation1 = compilation0.WithSource(source).WithReferences(MscorlibRef, lib1.ToMetadataReference());
PDB\CheckSumTest.cs (2)
25new[] { MscorlibRef }, 303new[] { MscorlibRef },
PDB\PDBTests.cs (2)
50var comp = CSharpCompilation.Create("Compilation", new[] { tree1, tree2, tree3, tree4 }, new[] { MscorlibRef }, options: TestOptions.ReleaseDll); 70var comp = CSharpCompilation.Create("Compilation", new[] { tree1, tree2, tree3, tree4 }, new[] { MscorlibRef }, options: TestOptions.ReleaseDll);
Microsoft.CodeAnalysis.CSharp.Emit3.UnitTests (11)
Attributes\AttributeTests.cs (3)
4883references: new[] { MscorlibRef }, 4888var metadataStream2 = CSharpCompilation.Create("goo.dll", references: new[] { MscorlibRef, ref1 }, 4898var compilation = CSharpCompilation.Create("moo.dll", references: new[] { MscorlibRef, ref1, ref2 });
Attributes\AttributeTests_Security.cs (2)
1506new[] { MscorlibRef }, 1628new[] { MscorlibRef },
Attributes\AttributeTests_WellKnownAttributes.cs (2)
10284var cscomp = CreateEmptyCompilation(cssource, new[] { MscorlibRef, ilReference }, TestOptions.ReleaseExe); 10392var cscomp = CreateEmptyCompilation(cssource, new[] { MscorlibRef, ilReference }, TestOptions.ReleaseExe);
Attributes\InternalsVisibleToAndStrongNameTests.cs (4)
151new[] { MscorlibRef }, 181new[] { MscorlibRef }, 310new[] { MscorlibRef }, 357new[] { MscorlibRef },
Microsoft.CodeAnalysis.CSharp.IOperation.UnitTests (1)
IOperation\IOperationTests_IParameterReferenceExpression.cs (1)
987references: new[] { MscorlibRef, SystemRef, compilation0.EmitToImageReference(embedInteropTypes: true) });
Microsoft.CodeAnalysis.CSharp.Scripting.UnitTests (2)
ScriptTests.cs (2)
198, ScriptOptions.WithReferences(MscorlibRef, SystemRef, SystemCoreRef, CSharpRef)); 213, ScriptOptions.WithReferences(MscorlibRef, SystemRef, SystemCoreRef, CSharpRef));
Microsoft.CodeAnalysis.CSharp.Semantic.UnitTests (11)
Semantics\AccessibilityTests.cs (1)
69references: new MetadataReference[] { MscorlibRef }).GetWellKnownType(WellKnownType.System_Exception);
Semantics\LambdaTests.cs (2)
509references: new[] { MscorlibRef }, 560references: new[] { MscorlibRef },
Semantics\NullableReferenceTypesTests.cs (2)
116766var compilation6 = CreateEmptyCompilation(source2, options: WithNullableEnable(TestOptions.ReleaseDll), references: new[] { compilation1.EmitToImageReference(), MscorlibRef }); 116796var compilation7 = CreateEmptyCompilation(source2, options: WithNullableEnable(TestOptions.ReleaseDll), references: new[] { compilation1.ToMetadataReference(), MscorlibRef });
Semantics\RefLocalsAndReturnsTests.cs (1)
1998var comp = CreateCompilation(text, targetFramework: TargetFramework.Empty, references: new[] { MscorlibRef, SystemCoreRef });
Semantics\StructsTests.cs (2)
383new[] { MscorlibRef, new CSharpCompilationReference(c1) }, 390var mscorlibAssembly = c2.GetReferencedAssemblySymbol(MscorlibRef);
Semantics\SwitchTests.cs (1)
2420references: new[] { MscorlibRef, SystemCoreRef });
Semantics\UseSiteErrorTests.cs (2)
2389var compilation6 = CreateEmptyCompilation(source2, parseOptions: parseOptions, options: TestOptions.ReleaseDll, references: new[] { compilation1.EmitToImageReference(), MscorlibRef }); 2419var compilation7 = CreateEmptyCompilation(source2, parseOptions: parseOptions, options: TestOptions.ReleaseDll, references: new[] { compilation1.ToMetadataReference(), MscorlibRef });
Microsoft.CodeAnalysis.CSharp.Symbol.UnitTests (192)
BadSymbolReference.cs (6)
742MscorlibRef, 796var libRef = CreateEmptyCompilation(libSource, new[] { MscorlibRef }, assemblyName: "System.Drawing").EmitToImageReference(); 798var comp1 = CreateEmptyCompilation(project1Source, new[] { MscorlibRef, libRef }, assemblyName: "Project1"); 801var comp2 = CreateEmptyCompilation(project2Source, new[] { MscorlibRef, libRef }, assemblyName: "Project2"); 806var comp3 = CreateEmptyCompilation(project3Source, new[] { MscorlibRef, comp1.ToMetadataReference(), comp2.ToMetadataReference() }, assemblyName: "Project3"); 815var comp3 = CreateEmptyCompilation(project3Source, new[] { MscorlibRef, comp1.EmitToImageReference(), comp2.EmitToImageReference() }, assemblyName: "Project3");
Compilation\CompilationAPITests.cs (27)
387new[] { MscorlibRef }); 615references: new MetadataReference[] { MscorlibRef }); 625references: new MetadataReference[] { MscorlibRef, mtref } 636references: new MetadataReference[] { MscorlibRef, mtref } 649references: new MetadataReference[] { MscorlibRef, mtref } 683references: new MetadataReference[] { MscorlibRef }); 693references: new MetadataReference[] { MscorlibRef, mtref } 704references: new MetadataReference[] { MscorlibRef, mtref } 717references: new MetadataReference[] { MscorlibRef, mtref } 1351Assert.Null(comp.GetReferencedAssemblySymbol(reference: MscorlibRef)); 1443Assert.Throws<ArgumentException>(() => comp = comp.ReplaceReference(MscorlibRef, ref1)); 1690var compilation = CSharpCompilation.Create(assemblyName: null, options: TestOptions.ReleaseModule, syntaxTrees: new[] { Parse(source) }, references: new[] { MscorlibRef }); 1698compilation = CSharpCompilation.Create(assemblyName: null, options: TestOptions.ReleaseDll, syntaxTrees: new[] { Parse(source) }, references: new[] { MscorlibRef }); 1706compilation = CSharpCompilation.Create(assemblyName: "ModuleAssemblyName", options: TestOptions.ReleaseModule, syntaxTrees: new[] { Parse(source) }, references: new[] { MscorlibRef }); 1811references: new[] { MscorlibRef }, 1835references: new[] { MscorlibRef }, 1902var comp = CreateEmptyCompilation(text, references: new[] { MscorlibRef, alias }); 2044var c2 = c1.WithReferences(new[] { MscorlibRef }); 2047var c3 = c2.WithReferences(new[] { MscorlibRef, SystemCoreRef }); 2056c3 = c2.ReplaceReference(MscorlibRef, SystemCoreRef); 2059c3 = c2.RemoveReferences(MscorlibRef); 2206var c1 = CreateEmptyCompilation("public class Main { public static C C; }", new[] { MscorlibRef, reference, reference }); 2210var c5 = c4.WithReferences(new[] { MscorlibRef, reference }); 2237var c = CSharpCompilation.Create("Goo", references: new[] { MscorlibRef, mdModule.GetReference(display: "ModuleCS00") }, options: TestOptions.ReleaseDll); 2293references: new[] { MscorlibRef, NetFramework.System }, 2385CSharpCompilation.Create(assemblyName, new[] { tree1, tree2 }, new[] { MscorlibRef }, compilationOptions); 2388CSharpCompilation.Create(assemblyName, new[] { tree1, tree3 }, new[] { MscorlibRef }, compilationOptions);
Compilation\GetUnusedImportDirectivesTests.cs (1)
122var comp = CreateEmptyCompilation(text, new[] { MscorlibRef });
Compilation\ReferenceManagerTests.cs (65)
745var compilation = CreateEmptyCompilation(tree, new[] { MscorlibRef, r1, r2_SysCore }, TestOptions.DebugExe, assemblyName: "Test"); 1336references: new[] { MscorlibRef, SystemCoreRef, SystemRef }); 2248CreateEmptyCompilation(@"[assembly: System.Reflection.AssemblyVersion(""1.0.0.0"")] public class C {}", new[] { MscorlibRef }, assemblyName: "C").EmitToImageReference(), 2249CreateEmptyCompilation(@"[assembly: System.Reflection.AssemblyVersion(""2.0.0.0"")] public class C {}", new[] { MscorlibRef }, assemblyName: "C").ToMetadataReference(), 2266CreateEmptyCompilation(@"[assembly: System.Reflection.AssemblyVersion(""0.0.0.0"")] public class C {}", new[] { MscorlibRef }, assemblyName: "C").ToMetadataReference(), 2267CreateEmptyCompilation(@"[assembly: System.Reflection.AssemblyVersion(""2.0.0.1"")] public class C {}", new[] { MscorlibRef }, assemblyName: "C").ToMetadataReference(), 2268CreateEmptyCompilation(@"[assembly: System.Reflection.AssemblyVersion(""1.0.0.0"")] public class C {}", new[] { MscorlibRef }, assemblyName: "C").ToMetadataReference(), 2269CreateEmptyCompilation(@"[assembly: System.Reflection.AssemblyVersion(""2.0.0.0"")] public class C {}", new[] { MscorlibRef }, assemblyName: "C").ToMetadataReference(), 2270CreateEmptyCompilation(@"[assembly: System.Reflection.AssemblyVersion(""1.1.0.0"")] public class C {}", new[] { MscorlibRef }, assemblyName: "C").ToMetadataReference(). 2398MscorlibRef, 2434MscorlibRef, 2472MscorlibRef, 2511MscorlibRef, 2577var b1Ref = CreateEmptyCompilation(@"[assembly: System.Reflection.AssemblyVersion(""1.0.0.0"")] public class B { }", new[] { MscorlibRef }, options: s_signedDll, assemblyName: "B").EmitToImageReference(); 2578var b2Ref = CreateEmptyCompilation(@"[assembly: System.Reflection.AssemblyVersion(""2.0.0.0"")] public class B { }", new[] { MscorlibRef }, options: s_signedDll, assemblyName: "B").EmitToImageReference(); 2579var b3Ref = CreateEmptyCompilation(@"[assembly: System.Reflection.AssemblyVersion(""3.0.0.0"")] public class B { }", new[] { MscorlibRef }, options: s_signedDll, assemblyName: "B").EmitToImageReference(); 2581var aRef = CreateEmptyCompilation("public class A : B { }", new[] { MscorlibRef, b1Ref }, assemblyName: "A").EmitToImageReference(); 2582var dRef = CreateEmptyCompilation("public class D : B { }", new[] { MscorlibRef, b2Ref }, assemblyName: "D").EmitToImageReference(); 2601", new[] { MscorlibRef, aRef, dRef }, 2631var b1Ref = CreateEmptyCompilation(@"[assembly: System.Reflection.AssemblyVersion(""1.0.0.0"")] public interface B { }", new[] { MscorlibRef }, assemblyName: "B").EmitToImageReference(); 2632var b2Ref = CreateEmptyCompilation(@"[assembly: System.Reflection.AssemblyVersion(""2.0.0.0"")] public interface B { }", new[] { MscorlibRef }, assemblyName: "B").EmitToImageReference(); 2633var b3Ref = CreateEmptyCompilation(@"[assembly: System.Reflection.AssemblyVersion(""3.0.0.0"")] public interface B { }", new[] { MscorlibRef }, assemblyName: "B").EmitToImageReference(); 2634var b4Ref = CreateEmptyCompilation(@"[assembly: System.Reflection.AssemblyVersion(""4.0.0.0"")] public interface B { }", new[] { MscorlibRef }, assemblyName: "B").EmitToImageReference(); 2636var aRef = CreateEmptyCompilation(@"public interface A : B { }", new[] { MscorlibRef, b1Ref }, assemblyName: "A").EmitToImageReference(); 2637var dRef = CreateEmptyCompilation(@"public interface D : B { }", new[] { MscorlibRef, b2Ref }, assemblyName: "D").EmitToImageReference(); 2667var b1Ref = CreateEmptyCompilation(@"[assembly: System.Reflection.AssemblyVersion(""1.0.0.0"")] public interface B { }", new[] { MscorlibRef }, assemblyName: "B").EmitToImageReference(); 2668var b2Ref = CreateEmptyCompilation(@"[assembly: System.Reflection.AssemblyVersion(""2.0.0.0"")] public interface B { }", new[] { MscorlibRef }, assemblyName: "B").EmitToImageReference(); 2669var b3Ref = CreateEmptyCompilation(@"[assembly: System.Reflection.AssemblyVersion(""3.0.0.0"")] public interface B { }", new[] { MscorlibRef }, assemblyName: "B").EmitToImageReference(); 2670var b4Ref = CreateEmptyCompilation(@"[assembly: System.Reflection.AssemblyVersion(""4.0.0.0"")] public interface B { }", new[] { MscorlibRef }, assemblyName: "B").EmitToImageReference(); 2672var aRef = CreateEmptyCompilation(@"public interface A : B { }", new[] { MscorlibRef, b1Ref }, assemblyName: "A").EmitToImageReference(); 2673var dRef = CreateEmptyCompilation(@"public interface D : B { }", new[] { MscorlibRef, b2Ref }, assemblyName: "D").EmitToImageReference(); 2873var b1Ref = CreateEmptyCompilation(@"[assembly: System.Reflection.AssemblyVersion(""1.0.0.0"")] public interface B { }", new[] { MscorlibRef }, options: s_signedDll, assemblyName: "B").EmitToImageReference(); 2874var b2Ref = CreateEmptyCompilation(@"[assembly: System.Reflection.AssemblyVersion(""2.0.0.0"")] public interface B { }", new[] { MscorlibRef }, options: s_signedDll, assemblyName: "B").EmitToImageReference(); 2876var dRef = CreateEmptyCompilation(@"[assembly: System.Reflection.AssemblyVersion(""1.0.0.0"")] public interface D : B { }", new[] { MscorlibRef, b2Ref }, options: s_signedDll, assemblyName: "D").EmitToImageReference(); 2877var eRef = CreateEmptyCompilation(@"[assembly: System.Reflection.AssemblyVersion(""1.0.0.0"")] public interface E : B { }", new[] { MscorlibRef, b1Ref }, options: s_signedDll, assemblyName: "E").EmitToImageReference(); 2885var aRef = CreateEmptyCompilation(@"[assembly: System.Reflection.AssemblyVersion(""1.0.0.0"")] public interface A : D, E { }", new[] { MscorlibRef, dRef, eRef }, 2896var c = CreateEmptyCompilation("public class C : A { }", new[] { MscorlibRef, aRef, b1Ref }, 2939var b1Ref = CreateEmptyCompilation(@"[assembly: System.Reflection.AssemblyVersion(""1.0.0.0"")] public interface B { }", references: new[] { MscorlibRef }, options: s_signedDll, assemblyName: "B").EmitToImageReference(); 2940var b2Ref = CreateEmptyCompilation(@"[assembly: System.Reflection.AssemblyVersion(""2.0.0.0"")] public interface B { }", references: new[] { MscorlibRef }, options: s_signedDll, assemblyName: "B").EmitToImageReference(); 2942var dRef = CreateEmptyCompilation(@"[assembly: System.Reflection.AssemblyVersion(""1.0.0.0"")] public interface D : B { }", new[] { MscorlibRef, b2Ref }, options: s_signedDll, assemblyName: "D").EmitToImageReference(); 2943var eRef = CreateEmptyCompilation(@"[assembly: System.Reflection.AssemblyVersion(""1.0.0.0"")] public interface E : B { }", new[] { MscorlibRef, b1Ref }, options: s_signedDll, assemblyName: "E").EmitToImageReference(); 2951var aRef = CreateEmptyCompilation(@"[assembly: System.Reflection.AssemblyVersion(""1.0.0.0"")] public interface A : D, E { }", new[] { MscorlibRef, dRef, eRef }, 2962var c = CreateEmptyCompilation("public class C : A { }", new[] { MscorlibRef, aRef, b2Ref }, 2999var b1Ref = CreateEmptyCompilation(@"[assembly: System.Reflection.AssemblyVersion(""1.0.0.0"")] public interface B { }", new[] { MscorlibRef }, options: s_signedDll, assemblyName: "B").EmitToImageReference(); 3000var b2Ref = CreateEmptyCompilation(@"[assembly: System.Reflection.AssemblyVersion(""2.0.0.0"")] public interface B { }", new[] { MscorlibRef }, options: s_signedDll, assemblyName: "B").EmitToImageReference(); 3002var dRef = CreateEmptyCompilation(@"[assembly: System.Reflection.AssemblyVersion(""1.0.0.0"")] public interface D : B { }", new[] { MscorlibRef, b2Ref }, options: s_signedDll, assemblyName: "D").EmitToImageReference(); 3003var eRef = CreateEmptyCompilation(@"[assembly: System.Reflection.AssemblyVersion(""1.0.0.0"")] public interface E : B { }", new[] { MscorlibRef, b1Ref }, options: s_signedDll, assemblyName: "E").EmitToImageReference(); 3005var aRef = CreateEmptyCompilation(@"[assembly: System.Reflection.AssemblyVersion(""1.0.0.0"")] public interface A : D, E { }", new[] { MscorlibRef, dRef, eRef, b1Ref, b2Ref }, 3043var b1Ref = CreateEmptyCompilation(@"[assembly: System.Reflection.AssemblyVersion(""1.0.0.0"")] public interface B { }", new[] { MscorlibRef }, options: s_signedDll, assemblyName: "B").EmitToImageReference(); 3044var b2Ref = CreateEmptyCompilation(@"[assembly: System.Reflection.AssemblyVersion(""2.0.0.0"")] public interface B { }", new[] { MscorlibRef }, options: s_signedDll, assemblyName: "B").EmitToImageReference(); 3045var b3Ref = CreateEmptyCompilation(@"[assembly: System.Reflection.AssemblyVersion(""3.0.0.0"")] public interface B { }", new[] { MscorlibRef }, options: s_signedDll, assemblyName: "B").EmitToImageReference(); 3046var b4Ref = CreateEmptyCompilation(@"[assembly: System.Reflection.AssemblyVersion(""4.0.0.0"")] public interface B { }", new[] { MscorlibRef }, options: s_signedDll, assemblyName: "B").EmitToImageReference(); 3048var dRef = CreateEmptyCompilation(@"[assembly: System.Reflection.AssemblyVersion(""1.0.0.0"")] public interface D : B { }", new[] { MscorlibRef, b2Ref }, options: s_signedDll, assemblyName: "D").EmitToImageReference(); 3049var eRef = CreateEmptyCompilation(@"[assembly: System.Reflection.AssemblyVersion(""1.0.0.0"")] public interface E : B { }", new[] { MscorlibRef, b1Ref }, options: s_signedDll, assemblyName: "E").EmitToImageReference(); 3051var aRef = CreateEmptyCompilation(@"[assembly: System.Reflection.AssemblyVersion(""1.0.0.0"")] public interface A : D, E { }", new[] { MscorlibRef, dRef, eRef, b1Ref, b2Ref }, 3062var c = CreateEmptyCompilation("public class C : A { }", new[] { MscorlibRef, aRef }, 3109var b1Ref = CreateEmptyCompilation(@"[assembly: System.Reflection.AssemblyVersion(""1.0.0.0"")] public interface B { }", new[] { MscorlibRef }, options: s_signedDll, assemblyName: "B").EmitToImageReference(); 3110var b2Ref = CreateEmptyCompilation(@"[assembly: System.Reflection.AssemblyVersion(""2.0.0.0"")] public interface B { }", new[] { MscorlibRef }, options: s_signedDll, assemblyName: "B").EmitToImageReference(); 3111var b3Ref = CreateEmptyCompilation(@"[assembly: System.Reflection.AssemblyVersion(""3.0.0.0"")] public interface B { }", new[] { MscorlibRef }, options: s_signedDll, assemblyName: "B").EmitToImageReference(); 3112var b4Ref = CreateEmptyCompilation(@"[assembly: System.Reflection.AssemblyVersion(""4.0.0.0"")] public interface B { }", new[] { MscorlibRef }, options: s_signedDll, assemblyName: "B").EmitToImageReference(); 3114var dRef = CreateEmptyCompilation(@"[assembly: System.Reflection.AssemblyVersion(""1.0.0.0"")] public interface D : B { }", new[] { MscorlibRef, b2Ref }, options: s_signedDll, assemblyName: "D").EmitToImageReference(); 3115var eRef = CreateEmptyCompilation(@"[assembly: System.Reflection.AssemblyVersion(""1.0.0.0"")] public interface E : B { }", new[] { MscorlibRef, b1Ref }, options: s_signedDll, assemblyName: "E").EmitToImageReference(); 3117var aRef = CreateEmptyCompilation(@"[assembly: System.Reflection.AssemblyVersion(""1.0.0.0"")] public interface A : D, E { }", new[] { MscorlibRef, dRef, eRef, b1Ref, b2Ref }, 3218var aRef = CreateEmptyCompilation(@"public interface A { C CA { get; } }", new[] { MscorlibRef, TestReferences.SymbolsTests.Versioning.C2 }, 3221var bRef = CreateEmptyCompilation(@"public interface B { C CB { get; } }", new[] { MscorlibRef, TestReferences.SymbolsTests.Versioning.C1 },
Compilation\SemanticModelGetDeclaredSymbolAPITests.cs (3)
2756references: new[] { MscorlibRef }); 3105new[] { MscorlibRef, ref1 }); 3734new[] { MscorlibRef });
DocumentationComments\CrefTests.cs (1)
5871new[] { MscorlibRef },
DocumentationComments\DocumentationCommentCompilerTests.cs (1)
4715var comp = CSharpCompilation.Create("Test", new[] { tree }, new[] { MscorlibRef }, TestOptions.ReleaseDll.WithXmlReferenceResolver(resolver));
SymbolDisplay\SymbolDisplayTests.cs (4)
5774var compA = CreateEmptyCompilation(sourceA, new[] { MscorlibRef }); 5780var compB = CreateVisualBasicCompilation(GetUniqueName(), "", referencedAssemblies: new[] { MscorlibRef, refA }); 5959var compB = CreateVisualBasicCompilation(GetUniqueName(), "", referencedAssemblies: new[] { MscorlibRef, refA }); 5984var compB = CreateVisualBasicCompilation(GetUniqueName(), "", referencedAssemblies: new[] { MscorlibRef, refA });
Symbols\CompilationCreationTests.cs (2)
2551MscorlibRef, 2862var compilation = CSharpCompilation.Create("foo", references: new[] { MscorlibRef, r }, syntaxTrees: new[] { st });
Symbols\ConversionTests.cs (1)
387.AddReferences(MscorlibRef)
Symbols\ExtensionMethodTests.cs (3)
2429references: new[] { MscorlibRef, LinqAssemblyRef }); 3270var reference1 = BasicCompilationUtils.CompileToMetadata(source1, references: new[] { MscorlibRef, SystemCoreRef, MsvbRef }); 3808var references = new[] { MscorlibRef, SystemCoreRef };
Symbols\ImplicitClassTests.cs (1)
29", new[] { MscorlibRef });
Symbols\IndexedPropertyTests.cs (1)
2179var reference2 = BasicCompilationUtils.CompileToMetadata(source2, references: new[] { MscorlibRef, reference1 });
Symbols\Metadata\MetadataMemberTests.cs (2)
186var compilation = CreateEmptyCompilation(text, new[] { MscorlibRef }); 238var compilation = CreateEmptyCompilation(text, new[] { MscorlibRef });
Symbols\Metadata\MetadataTypeTests.cs (4)
27var compilation = CreateEmptyCompilation(text, new[] { MscorlibRef }); 67var compilation = CreateEmptyCompilation(text, new[] { MscorlibRef }); 117var compilation = CreateEmptyCompilation(text, new[] { MscorlibRef }, options: TestOptions.ReleaseDll.WithMetadataImportOptions(MetadataImportOptions.Internal)); 216new[] { MscorlibRef },
Symbols\Retargeting\NoPia.cs (33)
283var LocalTypes1 = CreateEmptyCompilation(s_sourceLocalTypes1_IL, new[] { MscorlibRef }, options: TestOptions.ReleaseDll, assemblyName: "LocalTypes1"); 286var LocalTypes2 = CreateEmptyCompilation(s_sourceLocalTypes2_IL, new[] { MscorlibRef }, options: TestOptions.ReleaseDll, assemblyName: "LocalTypes2"); 291new MetadataReference[] { MscorlibRef }); 362MscorlibRef, 404MscorlibRef 479MscorlibRef, 492MscorlibRef 528MscorlibRef 557MscorlibRef 588MscorlibRef 619MscorlibRef 629MscorlibRef, 663MscorlibRef, 705MscorlibRef 780MscorlibRef, 793MscorlibRef 829MscorlibRef 858MscorlibRef 889MscorlibRef 920MscorlibRef 930MscorlibRef, 967MscorlibRef, 1009MscorlibRef 1084MscorlibRef, 1097MscorlibRef 1133MscorlibRef 1162MscorlibRef 1193MscorlibRef 1224MscorlibRef 1234MscorlibRef, 1365MscorlibRef 1918MscorlibRef 1968MscorlibRef
Symbols\Source\CustomModifierCopyTests.cs (22)
958var comp = CreateEmptyCompilation(source, new[] { MscorlibRef, SystemCoreRef, ilRef }); 1002var comp1 = CreateEmptyCompilation(source1, new[] { MscorlibRef, SystemCoreRef, ilRef, ValueTupleRef, SystemRuntimeFacadeRef, CSharpRef }); 1034var comp2 = CreateEmptyCompilation(source2, new[] { MscorlibRef, SystemCoreRef, ilRef, ValueTupleRef, SystemRuntimeFacadeRef, CSharpRef }); 1058var comp3 = CreateEmptyCompilation(source3, new[] { MscorlibRef, SystemCoreRef, ilRef, ValueTupleRef, SystemRuntimeFacadeRef, CSharpRef }); 1079var comp4 = CreateEmptyCompilation(source4, new[] { MscorlibRef, SystemCoreRef, ilRef, ValueTupleRef, SystemRuntimeFacadeRef, CSharpRef }); 1132var comp1 = CreateEmptyCompilation(source1, new[] { MscorlibRef, SystemCoreRef, ilRef, ValueTupleRef, SystemRuntimeFacadeRef, CSharpRef }); 1156var comp2 = CreateEmptyCompilation(source2, new[] { MscorlibRef, SystemCoreRef, ilRef, ValueTupleRef, SystemRuntimeFacadeRef, CSharpRef }); 1170var comp3 = CreateEmptyCompilation(source3, new[] { MscorlibRef, SystemCoreRef, ilRef, ValueTupleRef, SystemRuntimeFacadeRef, CSharpRef }); 1279var comp1 = CreateEmptyCompilation(source1, new[] { MscorlibRef, SystemCoreRef, ilRef, ValueTupleRef, SystemRuntimeFacadeRef, CSharpRef }); 1320var comp2 = CreateEmptyCompilation(source2, new[] { MscorlibRef, SystemCoreRef, ilRef, ValueTupleRef, SystemRuntimeFacadeRef, CSharpRef }); 1348var comp3 = CreateEmptyCompilation(source3, new[] { MscorlibRef, SystemCoreRef, ilRef, ValueTupleRef, SystemRuntimeFacadeRef, CSharpRef }); 1395var comp = CreateEmptyCompilation(source, new[] { MscorlibRef, SystemCoreRef, ilRef }); 1435var comp = CreateEmptyCompilation(source, new[] { MscorlibRef, SystemCoreRef, ilRef }); 1480var comp = CreateEmptyCompilation(source, new[] { MscorlibRef, SystemCoreRef, ilRef }); 1524var comp = CreateEmptyCompilation(source, new[] { MscorlibRef, SystemCoreRef, ilRef }); 1579var comp = CreateEmptyCompilation(source, new[] { MscorlibRef, SystemCoreRef, ilRef }); 1633var comp = CreateEmptyCompilation(source, new[] { MscorlibRef, SystemCoreRef, ilRef }); 1683var comp = CreateEmptyCompilation(source, new[] { MscorlibRef, SystemCoreRef, ilRef }); 1768var comp = CreateEmptyCompilation(source, new[] { MscorlibRef, SystemCoreRef, ilRef }); 1885var comp = CreateEmptyCompilation(source, new[] { MscorlibRef, SystemCoreRef, ilRef }); 1982var comp = CreateEmptyCompilation(source, new[] { MscorlibRef, SystemCoreRef, ilRef }); 2084var comp = CreateEmptyCompilation(source, new[] { MscorlibRef, SystemCoreRef, ilRef });
Symbols\Source\EnumTests.cs (1)
933var compilation = CreateEmptyCompilation(text, new[] { MscorlibRef });
Symbols\Source\EventTests.cs (3)
370var comp = CreateEmptyCompilation(source, new[] { MscorlibRef, SystemCoreRef }); 382var libComp = CreateEmptyCompilation(source, new[] { MscorlibRef }).VerifyDiagnostics( 399var libComp = CreateEmptyCompilation(source, references: new[] { MscorlibRef }).VerifyDiagnostics(
Symbols\Source\ExternAliasTests.cs (1)
113references: new MetadataReference[] { MscorlibRef, ExternAliasTests.Goo1, ExternAliasTests.Goo2 });
Symbols\Source\LocationTests.cs (1)
26var comp = CreateEmptyCompilation(text, new[] { MscorlibRef });
Symbols\Source\PropertyTests.cs (2)
2608references: new MetadataReference[] { MscorlibRef }); 2700references: new[] { MscorlibRef });
Symbols\Source\SourcePlusMetadataTests.cs (5)
187var compilation = CreateEmptyCompilation(text, new[] { MscorlibRef }); 191var comp2 = CSharpCompilation.Create("Compilation2", references: new MetadataReference[] { ref2, MscorlibRef }); 203var compilation = CreateEmptyCompilation(text, new[] { MscorlibRef }); 207var comp2 = CSharpCompilation.Create("Compilation2", references: new MetadataReference[] { ref2, MscorlibRef }); 235var comp2 = CSharpCompilation.Create("Compilation2", references: new MetadataReference[] { ref2, MscorlibRef });
Symbols\SymbolDistinguisherTests.cs (1)
316var validType = CreateEmptyCompilation("", new[] { MscorlibRef }).GetSpecialType(SpecialType.System_Int32);
Symbols\TypeResolutionTests.cs (1)
121MscorlibRef,
Microsoft.CodeAnalysis.CSharp.Test.Utilities (2)
BasicCompilationUtils.cs (1)
23references = new[] { TestBase.MscorlibRef };
DiagnosticTestUtilities.cs (1)
77return VerifyErrorsAndGetCompilation(trees, refs.Concat(CSharpTestBase.MscorlibRef), expectedErrorDesp);
Microsoft.CodeAnalysis.CSharp.WinRT.UnitTests (3)
PdbTests.cs (3)
77new[] { MscorlibRef }); 93new[] { MscorlibRef }); 110new[] { MscorlibRef });
Microsoft.CodeAnalysis.EditorFeatures.Test.Utilities (1)
Semantics\SpeculationAnalyzerTestsBase.cs (1)
23MscorlibRef,
Microsoft.CodeAnalysis.EditorFeatures.UnitTests (1)
Diagnostics\SuppressMessageAttributeWorkspaceTests.cs (1)
50references: [TestBase.MscorlibRef]).EmitToImageReference();
Microsoft.CodeAnalysis.Test.Utilities (2)
CommonTestBase.cs (2)
373references.Add(MscorlibRef); 460references.Add(MscorlibRef);
Microsoft.CodeAnalysis.UnitTests (12)
Diagnostics\AnalysisContextInfoTests.cs (1)
118references: new[] { TestBase.MscorlibRef });
Diagnostics\SuppressMessageAttributeCompilerTests.cs (2)
61references: new[] { TestBase.MscorlibRef }).EmitToImageReference(); 63return ImmutableArray.Create(TestBase.MscorlibRef, compRef, TestBase.ValueTupleRef);
Diagnostics\SuppressMessageTargetSymbolResolverTests.cs (2)
1434references: new[] { TestBase.MscorlibRef }); 1442references: new[] { TestBase.MscorlibRef });
GivesAccessTo.cs (4)
44var csc = (Compilation)CSharpCompilation.Create("CS", new[] { csharpTree }, new MetadataReference[] { TestBase.MscorlibRef }); 47var csc2 = (Compilation)CSharpCompilation.Create("CS2", new[] { csharpTree2 }, new MetadataReference[] { TestBase.MscorlibRef }); 50var vbc = VisualBasicCompilation.Create("VB", new[] { vbTree }, new MetadataReference[] { TestBase.MscorlibRef }); 53var vbc2 = VisualBasicCompilation.Create("VB2", new[] { vbTree2 }, new MetadataReference[] { TestBase.MscorlibRef });
IsSymbolAccessibleWithinTests.cs (2)
28var csc = CSharpCompilation.Create("CS", new[] { csharpTree }, new MetadataReference[] { TestBase.MscorlibRef }) as Compilation; 31var vbc = VisualBasicCompilation.Create("VB", new[] { vbTree }, new MetadataReference[] { TestBase.MscorlibRef }) as Compilation;
MetadataReferences\MetadataReferenceTests.cs (1)
526var f1 = MscorlibRef;
Microsoft.CodeAnalysis.VisualBasic.Emit.UnitTests (5)
Attributes\InternalsVisibleToAndStrongNameTests.vb (5)
80{MscorlibRef}, 110{MscorlibRef}, 139references:={MscorlibRef}, 197Dim references = {MscorlibRef} 255Dim references = {MscorlibRef}
Microsoft.CodeAnalysis.VisualBasic.Semantic.UnitTests (16)
Compilation\CompilationAPITests.vb (16)
657{MscorlibRef, MsvbRef}, 1477Dim comp = VisualBasicCompilation.Create("test", references:={MscorlibRef}) ' no ValueTuple 1493Dim comp = VisualBasicCompilation.Create("test", references:={MscorlibRef}) ' no ValueTuple 2066Dim c = VisualBasicCompilation.Create(assemblyName:=Nothing, options:=TestOptions.ReleaseModule, syntaxTrees:={Parse(source)}, references:={MscorlibRef}) 2073c = VisualBasicCompilation.Create(assemblyName:=Nothing, options:=TestOptions.ReleaseModule, syntaxTrees:={Parse(source)}, references:={MscorlibRef}) 2080c = VisualBasicCompilation.Create(assemblyName:="ModuleAssemblyName", options:=TestOptions.ReleaseModule, syntaxTrees:={Parse(source)}, references:={MscorlibRef}) 2173references:={MscorlibRef}, 2197references:={MscorlibRef}, 2305Dim c2 = c1.WithReferences({MscorlibRef}) 2308Dim c3 = c2.WithReferences({MscorlibRef, SystemCoreRef}) 2317c3 = c2.ReplaceReference(MscorlibRef, SystemCoreRef) 2320c3 = c2.RemoveReferences(MscorlibRef) 2455Dim c5 = c4.WithReferences({MscorlibRef, reference}) 2476Dim c = VisualBasicCompilation.Create("Goo", references:={MscorlibRef, mdModule.GetReference(display:="ModuleCS00")}, options:=TestOptions.ReleaseDll) 2600VisualBasicCompilation.Create(assemblyName, {tree1, tree2}, {MscorlibRef}, CompilationOptions) 2601Assert.Throws(Of ArgumentException)(Function() VisualBasicCompilation.Create(assemblyName, {tree1, tree3}, {MscorlibRef}, CompilationOptions))
Microsoft.CodeAnalysis.VisualBasic.Test.Utilities (2)
BasicTestBase.vb (1)
395Dim compilation = CreateEmptyCompilationWithReferences(source, {MscorlibRef, MsvbRef, reference}, options)
CompilationTestUtils.vb (1)
219Dim references = {MscorlibRef, SystemRef, MsvbRef}
Microsoft.CodeAnalysis.Workspaces.UnitTests (26)
FindAllDeclarationsTests.cs (5)
137.AddMetadataReference(csharpId, MscorlibRef); 142.AddMetadataReference(vbId, MscorlibRef); 163.AddMetadataReference(submission0Id, MscorlibRef) 178.AddMetadataReference(submission1Id, MscorlibRef) 701.AddMetadataReference(pid, MscorlibRef);
FindAllDeclarationsTests.TestSolutionsAndProject.cs (2)
96.AddMetadataReference(pid, MscorlibRef); 116.AddMetadataReference(pid, MscorlibRef);
FindReferencesTests.cs (7)
65.AddMetadataReference(pid, MscorlibRef) 75.AddMetadataReference(pid, MscorlibRef); 124.AddMetadataReference(pid, MscorlibRef) 125.AddMetadataReference(pid, ((PortableExecutableReference)MscorlibRef).WithAliases(["X"])) 174.AddMetadataReference(prj1Id, MscorlibRef) 213.AddMetadataReference(prj1Id, MscorlibRef) 277.AddMetadataReference(prj1Id, MscorlibRef)
SolutionTests\SolutionTests.cs (12)
4056metadataReferences: [MscorlibRef], 4068metadataReferences: [MscorlibRef], 4088metadataReferences: [MscorlibRef])); 4098metadataReferences: [MscorlibRef], 4261metadataReferences: [MscorlibRef], 4274metadataReferences: [MscorlibRef], 5370metadataReferences: [MscorlibRef], 5384metadataReferences: [MscorlibRef], 5397metadataReferences: [MscorlibRef], 5411metadataReferences: [MscorlibRef], 5425metadataReferences: [MscorlibRef], 5435metadataReferences: [MscorlibRef],
Microsoft.VisualStudio.LanguageServices.CSharp.UnitTests (1)
ProjectSystemShim\EntryPointFinderTests.cs (1)
37var compilation = CSharpCompilation.Create("Test", references: [TestBase.MscorlibRef]).AddSyntaxTrees(CSharpSyntaxTree.ParseText($$"""