18 references to WithPreAuthorizedApplication
Aspire.Hosting.Azure.EntraId (2)
EntraIdResourceExtensions.cs (2)
2562/// <see cref="WithPreAuthorizedApplication"/>. 2569/// or <paramref name="api"/> pre-authorizes the caller (<see cref="WithPreAuthorizedApplication"/>).
Aspire.Hosting.Azure.EntraId.Tests (16)
EntraIdApiProvisioningTests.cs (13)
528.WithPreAuthorizedApplication(web, "access_as_user"); 675.WithPreAuthorizedApplication(web, "access_as_user") 676.WithPreAuthorizedApplication(web, "other") 677.WithPreAuthorizedApplication(existingClient, "access_as_user"); 692Assert.Throws<ArgumentException>(() => api.WithPreAuthorizedApplication(web)); 693Assert.Throws<ArgumentException>(() => api.WithPreAuthorizedApplication(web, "unknown")); 694Assert.Throws<ArgumentException>(() => api.WithPreAuthorizedApplication(web, "retired")); 705var exception = Assert.Throws<InvalidOperationException>(() => api.WithPreAuthorizedApplication(web, "access_as_user")); 711other.WithPreAuthorizedApplication(otherWeb, "access_as_user"); 727Assert.Throws<InvalidOperationException>(() => c.WithPreAuthorizedApplication(a, "scope")); 737.WithPreAuthorizedApplication(existingWeb, "access_as_user"); 774api.WithPreAuthorizedApplication(daemon, "access_as_user"); 1365.WithPreAuthorizedApplication(shared, "read")
EntraIdPolyglotTests.cs (2)
448exportedApi.WithPreAuthorizedApplication(exportedClient, "access_as_user"); 473nativeApi.WithPreAuthorizedApplication(nativeClient, "access_as_user");
EntraIdProvisioningTests.cs (1)
198"pre-authorization" => entra.WithPreAuthorizedApplication(targetApi, "read"),