52 references to LayoutComponent
aspire (20)
Commands\DcpWorkloadCleanupService.cs (1)
27layoutDiscovery.GetComponentPath(LayoutComponent.Dcp, executionContext.WorkingDirectory.FullName);
Layout\LayoutConfiguration.cs (12)
62public string? GetComponentPath(LayoutComponent component) 71LayoutComponent.Cli => Components.Cli, 72LayoutComponent.Dcp => Components.Dcp, 73LayoutComponent.Dashboard => Components.Dashboard, 74LayoutComponent.Managed => Components.Managed, 75LayoutComponent.Tray => Components.Tray, 76LayoutComponent.TerminalHost => Components.TerminalHost, 86public string? GetDcpPath() => GetComponentPath(LayoutComponent.Dcp); 92public string? GetTrayPath() => GetComponentPath(LayoutComponent.Tray); 100var managedDir = GetComponentPath(LayoutComponent.Managed); 115var dashboardDir = GetComponentPath(LayoutComponent.Dashboard); 130var directory = GetComponentPath(LayoutComponent.TerminalHost);
Layout\LayoutDiscovery.cs (5)
26string? GetComponentPath(LayoutComponent component, string? projectDirectory = null); 117public string? GetComponentPath(LayoutComponent component, string? projectDirectory = null) 122LayoutComponent.Dcp => _environment.GetEnvironmentVariable(BundleDiscovery.DcpPathEnvVar), 123LayoutComponent.Managed => _environment.GetEnvironmentVariable(BundleDiscovery.ManagedPathEnvVar), 385var dcpPath = layout.GetComponentPath(LayoutComponent.Dcp);
Processes\DcpExecutableResolver.cs (1)
29layoutDiscovery.GetComponentPath(LayoutComponent.Dcp, executionContext.WorkingDirectory.FullName);
Utils\EnvironmentChecker\DcpConnectionHealthCheck.cs (1)
37var dcpDirectory = layoutDiscovery.GetComponentPath(LayoutComponent.Dcp, executionContext.WorkingDirectory.FullName);
Aspire.Cli.Tests (32)
BundleServiceIntegrationTests.cs (4)
842public string? GetComponentPath(LayoutComponent component, string? projectDirectory = null) 847LayoutComponent.Managed => Path.Combine(bundleDir, BundleDiscovery.ManagedDirectoryName, 849LayoutComponent.Dashboard => Path.Combine(bundleDir, BundleDiscovery.DashboardDirectoryName), 850LayoutComponent.Dcp => Path.Combine(bundleDir, BundleDiscovery.DcpDirectoryName),
Commands\AppHostLauncherTests.cs (1)
1752public string? GetComponentPath(LayoutComponent component, string? projectDirectory = null) => null;
Commands\DashboardRunCommandTests.cs (1)
736public string? GetComponentPath(LayoutComponent component, string? projectDirectory = null) => layout.GetComponentPath(component);
Layout\LayoutConfigurationTests.cs (13)
14Assert.Equal(0, (int)LayoutComponent.Cli); 15Assert.Equal(1, (int)LayoutComponent.Dcp); 16Assert.Equal(2, (int)LayoutComponent.Managed); 17Assert.Equal(3, (int)LayoutComponent.Dashboard); 18Assert.Equal(5, (int)LayoutComponent.TerminalHost); 78[InlineData(true, true, true, LayoutComponent.Dashboard)] 79[InlineData(true, true, false, LayoutComponent.Dashboard)] 80[InlineData(true, false, true, LayoutComponent.Managed)] 82[InlineData(false, true, true, LayoutComponent.Managed)] 84[InlineData(false, false, true, LayoutComponent.Managed)] 86public void GetDashboardPath_SelectsCompatibleExistingExecutable(bool supportsNativeDashboard, bool nativeExists, bool managedExists, LayoutComponent? expectedComponent) 105LayoutComponent.Dashboard => dashboardPath, 106LayoutComponent.Managed => managedPath,
Layout\TrayLayoutTests.cs (1)
55Assert.Equal(layout.GetTrayPath(), discovery.GetComponentPath(LayoutComponent.Tray));
Processes\ProcessTreeGracefulShutdownServiceTests.cs (2)
478public string? GetComponentPath(LayoutComponent component, string? projectDirectory = null) 480return component == LayoutComponent.Dcp ? dcpDirectory : null;
Projects\PrebuiltAppHostServerTests.cs (2)
3128var dashboardDirectory = Assert.IsType<string>(layout.GetComponentPath(LayoutComponent.Dashboard)); 3239public string? GetComponentPath(LayoutComponent component, string? projectDirectory = null) => layout.GetComponentPath(component);
Utils\CliTestHelper.cs (4)
773public string? GetComponentPath(LayoutComponent component, string? projectDirectory = null) => null; 781private readonly Dictionary<LayoutComponent, string> _componentPaths = []; 788public FixedLayoutDiscovery(LayoutComponent component, string componentPath) 795public string? GetComponentPath(LayoutComponent component, string? projectDirectory = null) =>
Utils\DcpConnectionHealthCheckTests.cs (4)
48new FixedLayoutDiscovery(LayoutComponent.Dcp, dcpDirectory.FullName), 113new FixedLayoutDiscovery(LayoutComponent.Dcp, discoveredDcpDirectory.FullName), 185new FixedLayoutDiscovery(LayoutComponent.Dcp, dcpDirectory.FullName), 215new FixedLayoutDiscovery(LayoutComponent.Dcp, dcpDirectory.FullName),