165 references to ReleaseModule
Microsoft.CodeAnalysis.CSharp.Emit.UnitTests (26)
Emit\CompilationEmitTests.cs (24)
4048options: TestOptions.ReleaseModule.WithModuleName(name + extension)); 4210var compilation = CreateCompilation(source, options: TestOptions.ReleaseModule, assemblyName: "ContentType"); 4620var comp = CreateCompilation(source1, options: TestOptions.ReleaseModule); 4622CompileAndVerify(source2, references: new[] { metadataRef }, options: TestOptions.ReleaseModule, verify: Verification.Fails); 4704parseOptions: parseOptions, options: TestOptions.ReleaseModule.WithPlatform(Platform.AnyCpu)); 4710parseOptions: parseOptions, options: TestOptions.ReleaseModule.WithPlatform(Platform.AnyCpu)); 4732parseOptions: parseOptions, options: TestOptions.ReleaseModule.WithPlatform(Platform.X86)); 4740parseOptions: parseOptions, options: TestOptions.ReleaseModule.WithPlatform(Platform.X86)); 4763var refCompilation = CreateEmptyCompilation(refSource, parseOptions: parseOptions, options: TestOptions.ReleaseModule.WithPlatform(Platform.Itanium), assemblyName: "PlatformMismatch"); 4792parseOptions: parseOptions, options: TestOptions.ReleaseModule.WithPlatform(Platform.AnyCpu)); 4839parseOptions: parseOptions, options: TestOptions.ReleaseModule.WithPlatform(Platform.Itanium)); 4847parseOptions: parseOptions, options: TestOptions.ReleaseModule.WithPlatform(Platform.Itanium)); 4864var refCompilation = CreateEmptyCompilation(refSource, parseOptions: parseOptions, options: TestOptions.ReleaseModule.WithPlatform(Platform.X86), assemblyName: "PlatformMismatch"); 4922parseOptions: parseOptions, options: TestOptions.ReleaseModule.WithPlatform(Platform.Itanium)); 4928parseOptions: parseOptions, options: TestOptions.ReleaseModule.WithPlatform(Platform.Itanium)); 4943var refCompilation = CreateEmptyCompilation(refSource, parseOptions: parseOptions, options: TestOptions.ReleaseModule.WithPlatform(Platform.AnyCpu), assemblyName: "PlatformMismatch"); 4999parseOptions: parseOptions, options: TestOptions.ReleaseModule.WithPlatform(Platform.Itanium)); 5005parseOptions: parseOptions, options: TestOptions.ReleaseModule.WithPlatform(Platform.Itanium)); 5020var refCompilation = CreateEmptyCompilation(refSource, parseOptions: parseOptions, options: TestOptions.ReleaseModule.WithPlatform(Platform.Itanium), assemblyName: "PlatformMismatch"); 5262var comp1 = CreateCompilation(s1, options: TestOptions.ReleaseModule); 5266var comp2 = CreateCompilation(s2, options: TestOptions.ReleaseModule, references: new[] { ref1 }); 5309var comp1 = CreateCompilation(s1, options: TestOptions.ReleaseModule.WithModuleName("A")); 5313var comp2 = CreateCompilation(s2, options: TestOptions.ReleaseModule.WithModuleName("B"), references: new[] { ref1 }); 5549var modRef = CreateCompilation("public class A { }", options: TestOptions.ReleaseModule, assemblyName: "refMod").EmitToImageReference();
Emit\EmitErrorTests.cs (1)
264var netModule = CreateCompilation(moduleSource, options: TestOptions.ReleaseModule, assemblyName: "ModuleNameMismatch");
Emit\EntryPointTests.cs (1)
1573var netModule = CreateCompilation(source, options: TestOptions.ReleaseModule);
Microsoft.CodeAnalysis.CSharp.Emit3.UnitTests (86)
Attributes\AttributeTests_Assembly.cs (33)
419compilation = compilation.WithOptions(TestOptions.ReleaseModule); 448compilation = compilation.WithOptions(TestOptions.ReleaseModule); 467compilation = compilation.WithOptions(TestOptions.ReleaseModule); 502compilation = compilation.WithOptions(TestOptions.ReleaseModule); 807{}", options: TestOptions.ReleaseModule); 1013var netmoduleCompilation = CreateCompilationWithMscorlib40(source, options: TestOptions.ReleaseModule, references: references, assemblyName: assemblyName); 1124options: TestOptions.ReleaseModule); 1177options: TestOptions.ReleaseModule, 1239options: TestOptions.ReleaseModule); 1432compilation = CreateCompilationWithMscorlib40(netmodule2Source, options: TestOptions.ReleaseModule, references: new[] { netmodule1Ref }); 1835var module = CreateCompilation(moduleSrc, options: TestOptions.ReleaseModule, assemblyName: "M"); 1932var module = CreateCompilation(moduleSrc, options: TestOptions.ReleaseModule, assemblyName: "M"); 1958var module1 = CreateCompilation(moduleSrc1, options: TestOptions.ReleaseModule, assemblyName: "M1"); 1965var module2 = CreateCompilation(moduleSrc2, options: TestOptions.ReleaseModule, assemblyName: "M2"); 1986var module1 = CreateCompilation(moduleSrc1, options: TestOptions.ReleaseModule, assemblyName: "M1"); 2011var module1 = CreateCompilation(moduleSrc1, options: TestOptions.ReleaseModule, assemblyName: "M1"); 2018var module2 = CreateCompilation(moduleSrc2, options: TestOptions.ReleaseModule, assemblyName: "M2"); 2039var module1 = CreateCompilation(moduleSrc1, options: TestOptions.ReleaseModule, assemblyName: "M1"); 2064var module1 = CreateCompilation(moduleSrc1, options: TestOptions.ReleaseModule, assemblyName: "M1"); 2071var module2 = CreateCompilation(moduleSrc2, options: TestOptions.ReleaseModule, assemblyName: "M2"); 2090var module1 = CreateCompilation(moduleSrc1, options: TestOptions.ReleaseModule, assemblyName: "M1"); 2116var compMod1 = CreateCompilation(mod1Source, options: TestOptions.ReleaseModule, assemblyName: "M1"); 2117var compMod2 = CreateCompilation(mod2Source, options: TestOptions.ReleaseModule, assemblyName: "M2"); 2148var compMod1 = CreateCompilation(mod1Source, options: TestOptions.ReleaseModule, assemblyName: "M1"); 2149var compMod2 = CreateCompilation(mod2Source, options: TestOptions.ReleaseModule, assemblyName: "M2"); 2178var compMod1 = CreateCompilation(mod1Source, options: TestOptions.ReleaseModule, assemblyName: "M1"); 2179var compMod2 = CreateCompilation(mod2Source, options: TestOptions.ReleaseModule, assemblyName: "M2"); 2210var compMod1 = CreateCompilation(mod1Source, options: TestOptions.ReleaseModule, assemblyName: "M1"); 2211var compMod2 = CreateCompilation(mod2Source, options: TestOptions.ReleaseModule, assemblyName: "M2"); 2237var compMod1 = CreateCompilation(mod1Source, options: TestOptions.ReleaseModule, assemblyName: "M1"); 2291var moduleWithAttribute = CreateCompilation(module, references: new[] { attributeDefinition1 }, options: TestOptions.ReleaseModule, assemblyName: "M1").EmitToImageReference(); 2347var module1WithAttribute = CreateCompilation(module1, references: new[] { c1Definition }, options: TestOptions.ReleaseModule, assemblyName: "M1").EmitToImageReference(); 2376var module2WithAttribute = CreateCompilation(module2, references: new[] { c1Definition }, options: TestOptions.ReleaseModule, assemblyName: "M1").EmitToImageReference();
Attributes\AttributeTests_Embedded.cs (2)
105}", options: TestOptions.ReleaseModule); 221var module = CreateCompilation(options: TestOptions.ReleaseModule, assemblyName: "testModule", source: @"
Attributes\AttributeTests_IsByRefLike.cs (4)
398CreateCompilation(code, options: TestOptions.ReleaseModule).VerifyDiagnostics( 415CreateCompilation(code, options: TestOptions.ReleaseModule).VerifyDiagnostics( 440CompileAndVerify(code, verify: Verification.Fails, references: new[] { reference }, options: TestOptions.ReleaseModule, symbolValidator: module => 516CreateCompilation(text, options: TestOptions.ReleaseModule).VerifyDiagnostics(
Attributes\AttributeTests_IsUnmanaged.cs (8)
258CompileAndVerify(text, verify: Verification.Fails, references: new[] { reference }, options: TestOptions.ReleaseModule, symbolValidator: module => 284CompileAndVerify(text, verify: Verification.Fails, references: new[] { reference }, options: TestOptions.ReleaseModule, symbolValidator: module => 320options: TestOptions.ReleaseModule.WithMetadataImportOptions(MetadataImportOptions.All), 349options: TestOptions.ReleaseModule.WithMetadataImportOptions(MetadataImportOptions.All), 665CreateCompilation(code, options: TestOptions.ReleaseModule).VerifyDiagnostics( 680CreateCompilation(code, options: TestOptions.ReleaseModule).VerifyDiagnostics( 702CreateCompilation(source: code, options: TestOptions.ReleaseModule.WithMetadataImportOptions(MetadataImportOptions.All)).VerifyDiagnostics( 713CreateCompilation(source: code, options: TestOptions.ReleaseModule.WithMetadataImportOptions(MetadataImportOptions.All)).VerifyDiagnostics(
Attributes\AttributeTests_NativeInteger.cs (2)
1174var comp = CreateCompilation(source, options: TestOptions.ReleaseModule); 1198var comp = CreateCompilation(source, options: TestOptions.ReleaseModule);
Attributes\AttributeTests_Nullable.cs (19)
993var comp = CreateCompilation(new[] { source }, parseOptions: TestOptions.Regular8, options: WithNullableEnable(TestOptions.ReleaseModule)); 1004var comp = CreateCompilation(source, parseOptions: TestOptions.Regular8, options: TestOptions.ReleaseModule); 2322var comp = CreateCompilation(source, options: TestOptions.ReleaseModule); 2349var comp = CreateCompilation(source, options: TestOptions.ReleaseModule); 4429var comp = CreateCompilation(new[] { source }, parseOptions: TestOptions.Regular8, options: WithNullableEnable(TestOptions.ReleaseModule)); 4449var comp = CreateCompilation(new[] { source }, parseOptions: TestOptions.Regular8, options: WithNullableEnable(TestOptions.ReleaseModule)); 4470var comp = CreateCompilation(new[] { source }, parseOptions: TestOptions.Regular8, options: WithNullableEnable(TestOptions.ReleaseModule)); 4488var comp = CreateCompilation(new[] { source }, parseOptions: TestOptions.Regular8, options: WithNullableEnable(TestOptions.ReleaseModule)); 4503var comp = CreateCompilation(new[] { source }, parseOptions: TestOptions.Regular8, options: WithNullableEnable(TestOptions.ReleaseModule)); 4518var comp = CreateCompilation(new[] { source }, parseOptions: TestOptions.Regular8, options: WithNullableEnable(TestOptions.ReleaseModule)); 4536var comp = CreateCompilation(new[] { source }, parseOptions: TestOptions.Regular8, options: WithNullableEnable(TestOptions.ReleaseModule)); 4560var comp = CreateCompilation(new[] { source }, parseOptions: TestOptions.Regular8, options: WithNullableEnable(TestOptions.ReleaseModule)); 4585var comp = CreateCompilation(new[] { source }, parseOptions: TestOptions.Regular8, options: WithNullableEnable(TestOptions.ReleaseModule)); 4606var comp = CreateCompilation(new[] { source }, parseOptions: TestOptions.Regular8, options: WithNullableEnable(TestOptions.ReleaseModule)); 4621var comp = CreateCompilation(new[] { source }, parseOptions: TestOptions.Regular8, options: WithNullableEnable(TestOptions.ReleaseModule)); 4647var comp = CreateCompilation(source, parseOptions: TestOptions.Regular8, options: TestOptions.ReleaseModule); 4669var comp = CreateCompilation(new[] { source }, parseOptions: TestOptions.Regular8, options: WithNullableEnable(TestOptions.ReleaseModule)); 4706var comp = CreateCompilation(new[] { source }, parseOptions: TestOptions.Regular8, options: WithNullableEnable(TestOptions.ReleaseModule)); 4725var comp = CreateCompilation(new[] { source }, parseOptions: TestOptions.Regular8, options: WithNullableEnable(TestOptions.ReleaseModule));
Attributes\AttributeTests_ReadOnlyStruct.cs (4)
388CreateCompilation(code, options: TestOptions.ReleaseModule).VerifyDiagnostics( 405CreateCompilation(code, options: TestOptions.ReleaseModule).VerifyDiagnostics( 432CompileAndVerify(code, verify: Verification.Fails, references: new[] { reference }, options: TestOptions.ReleaseModule, symbolValidator: module => 508CreateCompilation(text, options: TestOptions.ReleaseModule).VerifyDiagnostics(
Attributes\AttributeTests_RefReadOnly.cs (9)
1095CreateCompilation(code, options: TestOptions.ReleaseModule).VerifyDiagnostics( 1111CreateCompilation(code, options: TestOptions.ReleaseModule).VerifyDiagnostics( 1135CreateCompilation(code, options: TestOptions.ReleaseModule).VerifyDiagnostics( 1156CompileAndVerify(code, verify: Verification.Fails, references: new[] { reference }, options: TestOptions.ReleaseModule, symbolValidator: module => 1233CreateCompilation(text, options: TestOptions.ReleaseModule).VerifyDiagnostics( 1532var compilation = CreateCompilation(code, options: TestOptions.ReleaseModule, references: new[] { reference }); 1556var compilation = CreateCompilation(code, options: TestOptions.ReleaseModule); 2438var comp = CreateCompilation(source, options: TestOptions.ReleaseModule); 2464var comp = CreateCompilation(source, options: TestOptions.ReleaseModule);
Semantics\ExperimentalAttributeTests.cs (1)
533var moduleComp = CreateCompilation(libSrc, options: TestOptions.ReleaseModule, references: new[] { attrRef });
Semantics\ParamsCollectionTests.cs (4)
4453var comp5 = CreateCompilation(src2, references: [comp1.ToMetadataReference()], targetFramework: TargetFramework.Net80, options: TestOptions.ReleaseModule); 12770var comp3 = CreateCompilation(src1, references, options: TestOptions.ReleaseModule); 12774var comp4 = CreateCompilation(src1, references: references.Concat([comp1Ref]), options: TestOptions.ReleaseModule.WithMetadataImportOptions(MetadataImportOptions.All)); 12797var comp7 = CreateCompilation(src1, references: references.Concat([comp5Ref]), options: TestOptions.ReleaseModule);
Microsoft.CodeAnalysis.CSharp.Semantic.UnitTests (1)
Semantics\TopLevelStatementsTests.cs (1)
8074var comp = CreateCompilation(text, options: TestOptions.ReleaseModule, parseOptions: DefaultParseOptions);
Microsoft.CodeAnalysis.CSharp.Symbol.UnitTests (51)
Compilation\CompilationAPITests.cs (12)
981options: TestOptions.ReleaseModule, 987options: TestOptions.ReleaseModule, 1037options: TestOptions.ReleaseModule, 1043options: TestOptions.ReleaseModule, 1057options: TestOptions.ReleaseModule, 1092options: TestOptions.ReleaseModule, 1126options: TestOptions.ReleaseModule, 1132options: TestOptions.ReleaseModule, 1673var compilation = CreateCompilation(source, options: TestOptions.ReleaseModule); 1690var compilation = CSharpCompilation.Create(assemblyName: null, options: TestOptions.ReleaseModule, syntaxTrees: new[] { Parse(source) }, references: new[] { MscorlibRef }); 1706compilation = CSharpCompilation.Create(assemblyName: "ModuleAssemblyName", options: TestOptions.ReleaseModule, syntaxTrees: new[] { Parse(source) }, references: new[] { MscorlibRef }); 1981c1 = CSharpCompilation.Create("c", options: TestOptions.ReleaseModule);
Compilation\ReferenceManagerTests.cs (6)
1706var b = CreateCompilation(srcB, references: new[] { aRef }, options: TestOptions.ReleaseModule.WithModuleName("mod.netmodule"), assemblyName: "B"); 1764var moduleRef = CreateCompilation("public class TypeFromModule : TypeDependedOnByModule { }", new[] { assemblyRef }, options: TestOptions.ReleaseModule, assemblyName: "lib2").EmitToImageReference(); 1815var moduleRef = CreateCompilation("public class C { }", options: TestOptions.ReleaseModule, assemblyName: "lib").EmitToImageReference(); 1864var module = CreateCompilation(moduleSource, options: TestOptions.ReleaseModule); 2798var mRef = CreateCompilationWithMscorlib46("public interface M : B { }", new[] { bRef }, options: TestOptions.ReleaseModule.WithModuleName("M.netmodule")).EmitToImageReference(); 2799var nRef = CreateCompilationWithMscorlib46("public interface N : D { }", new[] { dRef }, options: TestOptions.ReleaseModule.WithModuleName("N.netmodule")).EmitToImageReference();
DocumentationComments\DocumentationCommentCompilerTests.cs (1)
6959var comp = CreateCompilationUtil(source, options: TestOptions.ReleaseModule);
Symbols\CompilationCreationTests.cs (1)
2972var lib1 = CreateCompilation(source1, assemblyName: "Lib1", options: TestOptions.ReleaseModule);
Symbols\Metadata\PE\TypeForwarders.cs (5)
1544var bits0 = CreateCompilation(module0, options: TestOptions.ReleaseModule, assemblyName: "asm0").EmitToArray(); 1618var modCompilation = CreateCompilation(mod, references: new[] { new CSharpCompilationReference(forwardedTypesCompilation) }, options: TestOptions.ReleaseModule); 1706appCompilation = CreateCompilation(app, references: new[] { modRef1, new CSharpCompilationReference(forwardedTypesCompilation) }, options: TestOptions.ReleaseModule); 1727var comp0 = CreateCompilation(source0, options: TestOptions.ReleaseModule, assemblyName: "asm0"); 1853", new[] { new CSharpCompilationReference(cC_v1) }, options: TestOptions.ReleaseModule, assemblyName: "D");
Symbols\ModuleInitializers\ModuleInitializersTests.cs (1)
815var moduleOptions = TestOptions.ReleaseModule.WithMetadataImportOptions(MetadataImportOptions.All);
Symbols\Retargeting\NoPia.cs (1)
2599var module1 = CreateCompilation(moduleSource, options: TestOptions.ReleaseModule, assemblyName: "Module1",
Symbols\Source\ClsComplianceTests.cs (11)
2366var trueModuleRef = CreateCompilation("[assembly:System.CLSCompliant(true)][module:System.CLSCompliant(true)]", options: TestOptions.ReleaseModule, assemblyName: "true").EmitToImageReference(); 2367var falseModuleRef = CreateCompilation("[assembly:System.CLSCompliant(false)][module:System.CLSCompliant(false)]", options: TestOptions.ReleaseModule, assemblyName: "false").EmitToImageReference(); 2368var noneModuleRef = CreateCompilation("", options: TestOptions.ReleaseModule, assemblyName: "none").EmitToImageReference(); 2401var trueModuleRef = CreateCompilation("[assembly:System.CLSCompliant(true)]", options: TestOptions.ReleaseModule, assemblyName: "true").EmitToImageReference(); 2402var falseModuleRef = CreateCompilation("[assembly:System.CLSCompliant(false)]", options: TestOptions.ReleaseModule, assemblyName: "false").EmitToImageReference(); 2403var noneModuleRef = CreateCompilation("", options: TestOptions.ReleaseModule, assemblyName: "none").EmitToImageReference(); 2434var trueModuleRef = CreateCompilation("[assembly:System.CLSCompliant(true)][module:System.CLSCompliant(true)]", options: TestOptions.ReleaseModule, assemblyName: "true").EmitToImageReference(); 2435var falseModuleRef = CreateCompilation("[assembly:System.CLSCompliant(false)][module:System.CLSCompliant(false)]", options: TestOptions.ReleaseModule, assemblyName: "false").EmitToImageReference(); 3866var comp1 = CreateCompilation(source1, options: TestOptions.ReleaseModule); 3890var comp3 = comp2.WithOptions(TestOptions.ReleaseModule.WithConcurrentBuild(false)); 3896comp3.WithOptions(TestOptions.ReleaseModule.WithConcurrentBuild(true)).VerifyDiagnostics(
Symbols\SymbolErrorTests.cs (13)
100var module1 = CreateCompilation(text1, options: TestOptions.ReleaseModule, assemblyName: name1); 103options: TestOptions.ReleaseModule, 6911var mod3Ref = CreateCompilation(mod3Source, options: TestOptions.ReleaseModule, assemblyName: "ErrTestMod03").EmitToImageReference(); 6996var mod3Ref = CreateCompilation(mod3Source, options: TestOptions.ReleaseModule, assemblyName: "ErrTestMod03").EmitToImageReference(); 7067var ModuleA01Ref = CreateCompilation(ModuleA01, options: TestOptions.ReleaseModule, assemblyName: "ModuleA01").EmitToImageReference(); 7075var ModuleB01Ref = CreateCompilation(ModuleB01, options: TestOptions.ReleaseModule, assemblyName: "ModuleB01").EmitToImageReference(); 7229var moduleRef2 = CreateCompilation(mod2Source, options: TestOptions.ReleaseModule, assemblyName: "mod_1_2").EmitToImageReference(); 7272options: TestOptions.ReleaseModule, 7283options: TestOptions.ReleaseModule, 7289options: TestOptions.ReleaseModule, 7295options: TestOptions.ReleaseModule, 7301options: TestOptions.ReleaseModule, 19084var netModule = CreateEmptyCompilation("", options: TestOptions.ReleaseModule, assemblyName: "lib").EmitToImageReference(expectedWarnings: new[] { Diagnostic(ErrorCode.WRN_NoRuntimeMetadataVersion) });
Microsoft.CodeAnalysis.CSharp.Test.Utilities (1)
TestOptions.cs (1)
99public static readonly CSharpCompilationOptions SigningReleaseModule = ReleaseModule.WithStrongNameProvider(SigningTestHelpers.DefaultDesktopStrongNameProvider);