public SdkResolutionFixture(SharedTestState state) { _builtDotnet = Path.Combine(TestArtifact.TestArtifactsPath, "sharedFrameworkPublish"); Dotnet = new DotNetCli(_builtDotnet); _fixture = state.HostApiInvokerAppFixture.Copy(); Directory.CreateDirectory(WorkingDir); // start with an empty global.json, it will be ignored, but prevent one lying on disk // on a given machine from impacting the test. File.WriteAllText(GlobalJson, "{}"); foreach (string sdk in ProgramFilesGlobalSdks) { Directory.CreateDirectory(Path.Combine(ProgramFilesGlobalSdkDir, sdk)); } foreach (string sdk in SelfRegisteredGlobalSdks) { Directory.CreateDirectory(Path.Combine(SelfRegisteredGlobalSdkDir, sdk)); } foreach (string sdk in LocalSdks) { Directory.CreateDirectory(Path.Combine(LocalSdkDir, sdk)); } }
public LightupAppActivation(LightupAppActivation.SharedTestState fixture) { sharedTestState = fixture; // From the artifacts dir, it's possible to find where the sharedFrameworkPublish folder is. We need // to locate it because we'll copy its contents into other folders string artifactsDir = new RepoDirectoriesProvider().GetTestContextVariable("TEST_ARTIFACTS"); string builtDotnet = Path.Combine(artifactsDir, "sharedFrameworkPublish"); // The dotnetLightupSharedFxLookup dir will contain some folders and files that will be necessary to perform the tests string sharedLookupDir = Path.Combine(artifactsDir, "dotnetLightupSharedFxLookup"); _baseDirArtifact = new TestArtifact(SharedFramework.CalculateUniqueTestDirectory(sharedLookupDir)); _fxBaseDir = Path.Combine(_baseDirArtifact.Location, "shared", "Microsoft.NETCore.App"); _uberFxBaseDir = Path.Combine(_baseDirArtifact.Location, "shared", "Microsoft.UberFramework"); SharedFramework.CopyDirectory(builtDotnet, _baseDirArtifact.Location); var repoDirectories = new RepoDirectoriesProvider(builtDotnet: _baseDirArtifact.Location); GlobalLightupClientFixture = new TestProjectFixture("LightupClient", repoDirectories) .EnsureRestored() .BuildProject(); string greatestVersionSharedFxPath = sharedTestState.LightupLibFixture_Built.BuiltDotnet.GreatestVersionSharedFxPath; string sharedFxVersion = (new DirectoryInfo(greatestVersionSharedFxPath)).Name; _builtSharedFxDir = Path.Combine(builtDotnet, "shared", "Microsoft.NETCore.App", sharedFxVersion); _builtSharedUberFxDir = Path.Combine(builtDotnet, "shared", "Microsoft.UberFramework", sharedFxVersion); SharedFramework.CreateUberFrameworkArtifacts(_builtSharedFxDir, _builtSharedUberFxDir, SystemCollectionsImmutableAssemblyVersion, SystemCollectionsImmutableFileVersion); }
public SDKLookup(SharedTestState sharedState) { SharedState = sharedState; string exeDotNetPath = SharedFramework.CalculateUniqueTestDirectory(sharedState.BaseDir); ExecutableDotNetBuilder = new DotNetBuilder(exeDotNetPath, sharedState.BuiltDotNet.BinPath, "exe"); ExecutableDotNet = ExecutableDotNetBuilder .AddMicrosoftNETCoreAppFrameworkMockHostPolicy("9999.0.0") .Build(); // Trace messages used to identify from which folder the SDK was picked ExecutableSelectedMessage = $"Using .NET SDK dll=[{Path.Combine(ExecutableDotNet.BinPath, "sdk")}"; // Note: no need to delete the directory, it will be removed once the entire class is done // since everything is under the BaseDir from the shared state }
public SdkResolutionFixture(SharedTestState state) { _fixture = state.PreviouslyPublishedAndRestoredPortableApiTestProjectFixture.Copy(); Directory.CreateDirectory(WorkingDir); // start with an empty global.json, it will be ignored, but prevent one lying on disk // on a given machine from impacting the test. File.WriteAllText(GlobalJson, "{}"); foreach (string sdk in GlobalSdks) { Directory.CreateDirectory(Path.Combine(GlobalSdkDir, sdk)); } foreach (string sdk in LocalSdks) { Directory.CreateDirectory(Path.Combine(LocalSdkDir, sdk)); } }
public BundleLegacy(SharedTestState fixture) { sharedTestState = fixture; }
public ResolveComponentDependencies(SharedTestState fixture) { sharedTestState = fixture; }
public GivenThatICareAboutHostVersionCompatibility(SharedTestState fixture) { sharedTestState = fixture; }
public IncludedFrameworksSettings(SharedTestState sharedState) { SharedState = sharedState; }
public AppHostUsedWithSymbolicLinks(AppHostUsedWithSymbolicLinks.SharedTestState fixture) { sharedTestState = fixture; }
public HammerServiceTest(SharedTestState fixture) { sharedTestState = fixture; }
public Comhost(SharedTestState sharedTestState) { sharedState = sharedTestState; }
public PortableAppActivation(SharedTestState fixture) { sharedTestState = fixture; }
public FXVersionCLI(SharedTestState sharedState) { SharedState = sharedState; }
public AppPerAssemblyVersionResolution(SharedTestState sharedState) : base(sharedState) { }
public Nethost(SharedTestState sharedTestState) { sharedState = sharedTestState; }
public PerAssemblyVersionResolutionBase(SharedTestState fixture) { SharedState = fixture; }
public ComponentPerAssemblyVersionResolution(SharedTestState sharedState) : base(sharedState) { }
public GivenThatICareAboutTracing(GivenThatICareAboutTracing.SharedTestState fixture) { sharedTestState = fixture; }
public BundleAndExtract(BundleAndExtract.SharedTestState fixture) { sharedTestState = fixture; }
public HostVersionCompatibility(SharedTestState fixture) { sharedTestState = fixture; }
public RollForwardAndRollForwardOnNoCandidateFxSettings(SharedTestState sharedState) { SharedState = sharedState; }
public BundledAppWithSubDirs(SharedTestState fixture) { sharedTestState = fixture; }
public ResolveComponentDependencies(SharedTestState fixture, ITestOutputHelper output) { sharedTestState = fixture; this.output = output; }
public MultiArchInstallLocation(SharedTestState fixture) { sharedTestState = fixture; }
public RollForwardOnNoCandidateFx(SharedTestState sharedState) { SharedState = sharedState; }
public GivenThatICareAboutDotnetArgValidationScenarios(GivenThatICareAboutDotnetArgValidationScenarios.SharedTestState fixture) { sharedTestState = fixture; }
public ClsidMapTests(SharedTestState fixture) { sharedTestState = fixture; }
public BundleExtractToSpecificPath(SharedTestState fixture) { sharedTestState = fixture; }
public DotnetArgValidation(DotnetArgValidation.SharedTestState fixture) { sharedTestState = fixture; }
public StandaloneAppActivation(StandaloneAppActivation.SharedTestState fixture) { sharedTestState = fixture; }