diff --git a/tests/DevApps/WebAppCallsWebApiCallsGraph/Client/Controllers/HomeController.cs b/tests/DevApps/WebAppCallsWebApiCallsGraph/Client/Controllers/HomeController.cs index 45879bd9c..83c0fd604 100644 --- a/tests/DevApps/WebAppCallsWebApiCallsGraph/Client/Controllers/HomeController.cs +++ b/tests/DevApps/WebAppCallsWebApiCallsGraph/Client/Controllers/HomeController.cs @@ -51,7 +51,7 @@ public async Task SayHello() var channel = GrpcChannel.ForAddress("https://localhost:5001"); var client = new Greeter.GreeterClient(channel); - string token = await _tokenAcquisition.GetAccessTokenForUserAsync(new string[] { "api://a4c2469b-cf84-4145-8f5f-cb7bacf814bc/access_as_user" }).ConfigureAwait(false); + string token = await _tokenAcquisition.GetAccessTokenForUserAsync(new string[] { "api://1e2fb196-50ce-4652-a4f9-26c1bf2e826b/access_as_user" }).ConfigureAwait(false); var headers = new Metadata(); headers.Add("Authorization", $"Bearer {token}"); diff --git a/tests/DevApps/WebAppCallsWebApiCallsGraph/Client/appsettings.json b/tests/DevApps/WebAppCallsWebApiCallsGraph/Client/appsettings.json index c57bdd087..63bed91ed 100644 --- a/tests/DevApps/WebAppCallsWebApiCallsGraph/Client/appsettings.json +++ b/tests/DevApps/WebAppCallsWebApiCallsGraph/Client/appsettings.json @@ -20,23 +20,23 @@ }, "TodoList": { // TodoListScope is the scope of the Web API you want to call. - "Scopes": [ "api://a4c2469b-cf84-4145-8f5f-cb7bacf814bc/access_as_user" ], + "Scopes": [ "api://1e2fb196-50ce-4652-a4f9-26c1bf2e826b/access_as_user" ], "BaseUrl": "http://localhost:44350" }, "SayHello": { // Scope for the web API set up w/gRPC - "Scopes": [ "api://a4c2469b-cf84-4145-8f5f-cb7bacf814bc/access_as_user" ], + "Scopes": [ "api://1e2fb196-50ce-4652-a4f9-26c1bf2e826b/access_as_user" ], "BaseUrl": "https://localhost:5001" }, "AzureFunction": { // Scope for the web API set up Azure function - "Scopes": [ "api://a4c2469b-cf84-4145-8f5f-cb7bacf814bc/access_as_user" ], + "Scopes": [ "api://1e2fb196-50ce-4652-a4f9-26c1bf2e826b/access_as_user" ], "BaseUrl": "http://localhost:7071/api/SampleFunc" }, "TodoListJwe": { // Scope for the web API used with the token decryption certificates. - "Scopes": [ "api://a4c2469b-cf84-4145-8f5f-cb7bacf814bc/access_as_user" ], + "Scopes": [ "api://1e2fb196-50ce-4652-a4f9-26c1bf2e826b/access_as_user" ], "BaseUrl": "https://localhost:44350" }, "Logging": { diff --git a/tests/DevApps/WebAppCallsWebApiCallsGraph/TodoListService/TodoListService.csproj b/tests/DevApps/WebAppCallsWebApiCallsGraph/TodoListService/TodoListService.csproj index 47e2090cd..a78365c86 100644 --- a/tests/DevApps/WebAppCallsWebApiCallsGraph/TodoListService/TodoListService.csproj +++ b/tests/DevApps/WebAppCallsWebApiCallsGraph/TodoListService/TodoListService.csproj @@ -12,4 +12,10 @@ + + + Always + + + diff --git a/tests/DevApps/WebAppCallsWebApiCallsGraph/TodoListService/appsettings.json b/tests/DevApps/WebAppCallsWebApiCallsGraph/TodoListService/appsettings.json index b41114d0d..ae01e5afc 100644 --- a/tests/DevApps/WebAppCallsWebApiCallsGraph/TodoListService/appsettings.json +++ b/tests/DevApps/WebAppCallsWebApiCallsGraph/TodoListService/appsettings.json @@ -15,7 +15,7 @@ // - WebAppsCallsWebApiCallGraph\\TodoListClient, // - Navigate to the todo list. this provokes a 401. // "Authority": "https://localhost:1234/v2.0", - "ClientId": "a4c2469b-cf84-4145-8f5f-cb7bacf814bc", //"712ae8d7-548a-4306-95b6-ee9117ee86f0", JWE clientID + "ClientId": "1e2fb196-50ce-4652-a4f9-26c1bf2e826b", //"712ae8d7-548a-4306-95b6-ee9117ee86f0", JWE clientID //"ClientSecret": null, "ClientCertificates": [ { diff --git a/tests/DevApps/WebAppCallsWebApiCallsGraph/gRPC/appsettings.json b/tests/DevApps/WebAppCallsWebApiCallsGraph/gRPC/appsettings.json index a9af74ddc..678db5f5d 100644 --- a/tests/DevApps/WebAppCallsWebApiCallsGraph/gRPC/appsettings.json +++ b/tests/DevApps/WebAppCallsWebApiCallsGraph/gRPC/appsettings.json @@ -3,7 +3,7 @@ "Instance": "https://login.microsoftonline.com/", "Domain": "msidentitysamplestesting.onmicrosoft.com", "TenantId": "7f58f645-c190-4ce5-9de4-e2b7acd2a6ab", - "ClientId": "a4c2469b-cf84-4145-8f5f-cb7bacf814bc", + "ClientId": "1e2fb196-50ce-4652-a4f9-26c1bf2e826b", "ClientCertificates": [ { "SourceType": "KeyVault", diff --git a/tests/DevApps/aspnet-mvc/OwinWebApi/appsettings.json b/tests/DevApps/aspnet-mvc/OwinWebApi/appsettings.json index ac6c9156a..24a901697 100644 --- a/tests/DevApps/aspnet-mvc/OwinWebApi/appsettings.json +++ b/tests/DevApps/aspnet-mvc/OwinWebApi/appsettings.json @@ -3,7 +3,7 @@ "Instance": "https://login.microsoftonline.com/", "Domain": "msidentitysamplestesting.onmicrosoft.com", "TenantId": "7f58f645-c190-4ce5-9de4-e2b7acd2a6ab", - "ClientId": "a4c2469b-cf84-4145-8f5f-cb7bacf814bc", //"712ae8d7-548a-4306-95b6-ee9117ee86f0", JWE clientID + "ClientId": "1e2fb196-50ce-4652-a4f9-26c1bf2e826b", //"712ae8d7-548a-4306-95b6-ee9117ee86f0", JWE clientID // "ClientSecret": "", "Scopes": "access_as_user", "EnableCacheSynchronization": false, diff --git a/tests/DevApps/blazorwasm2-b2c-hosted/Client/Properties/launchSettings.json b/tests/DevApps/blazorwasm2-b2c-hosted/Client/Properties/launchSettings.json index f6e38a765..3d24c31cd 100644 --- a/tests/DevApps/blazorwasm2-b2c-hosted/Client/Properties/launchSettings.json +++ b/tests/DevApps/blazorwasm2-b2c-hosted/Client/Properties/launchSettings.json @@ -1,30 +1,30 @@ { - "iisSettings": { - "windowsAuthentication": false, - "anonymousAuthentication": true, - "iisExpress": { - "applicationUrl": "http://localhost:59034", - "sslPort": 44365 - } - }, "profiles": { "IIS Express": { "commandName": "IISExpress", "launchBrowser": true, - "inspectUri": "{wsProtocol}://{url.hostname}:{url.port}/_framework/debug/ws-proxy?browser={browserInspectUri}", "environmentVariables": { "ASPNETCORE_ENVIRONMENT": "Development" - } + }, + "inspectUri": "{wsProtocol}://{url.hostname}:{url.port}/_framework/debug/ws-proxy?browser={browserInspectUri}" }, "blazorwasm2-b2c-hosted": { "commandName": "Project", - "dotnetRunMessages": "true", "launchBrowser": true, - "inspectUri": "{wsProtocol}://{url.hostname}:{url.port}/_framework/debug/ws-proxy?browser={browserInspectUri}", - "applicationUrl": "https://localhost:5001;http://localhost:5000", "environmentVariables": { "ASPNETCORE_ENVIRONMENT": "Development" - } + }, + "dotnetRunMessages": "true", + "inspectUri": "{wsProtocol}://{url.hostname}:{url.port}/_framework/debug/ws-proxy?browser={browserInspectUri}", + "applicationUrl": "https://localhost:5001;http://localhost:5000" + } + }, + "iisSettings": { + "windowsAuthentication": false, + "anonymousAuthentication": true, + "iisExpress": { + "applicationUrl": "http://localhost:49267/", + "sslPort": 44304 } } -} +} \ No newline at end of file diff --git a/tests/DevApps/blazorwasm2/Client/Program.cs b/tests/DevApps/blazorwasm2/Client/Program.cs index b2b9b0bfa..0c74053ab 100644 --- a/tests/DevApps/blazorwasm2/Client/Program.cs +++ b/tests/DevApps/blazorwasm2/Client/Program.cs @@ -27,7 +27,7 @@ public static async Task Main(string[] args) builder.Services.AddMsalAuthentication(options => { builder.Configuration.Bind("AzureAd", options.ProviderOptions.Authentication); - options.ProviderOptions.DefaultAccessTokenScopes.Add("api://a4c2469b-cf84-4145-8f5f-cb7bacf814bc/access_as_user"); + options.ProviderOptions.DefaultAccessTokenScopes.Add("api://1e2fb196-50ce-4652-a4f9-26c1bf2e826b/access_as_user"); }); await builder.Build().RunAsync(); diff --git a/tests/DevApps/blazorwasm2/Server/appsettings.json b/tests/DevApps/blazorwasm2/Server/appsettings.json index d420a3665..444753147 100644 --- a/tests/DevApps/blazorwasm2/Server/appsettings.json +++ b/tests/DevApps/blazorwasm2/Server/appsettings.json @@ -3,7 +3,7 @@ "Instance": "https://login.microsoftonline.com/", "Domain": "msidentitysamplestesting.onmicrosoft.com", "TenantId": "7f58f645-c190-4ce5-9de4-e2b7acd2a6ab", - "ClientId": "a4c2469b-cf84-4145-8f5f-cb7bacf814bc", + "ClientId": "1e2fb196-50ce-4652-a4f9-26c1bf2e826b", "CallbackPath": "/signin-oidc" }, // }, diff --git a/tests/DevApps/daemon-app/Daemon-app/Program-net60.cs b/tests/DevApps/daemon-app/Daemon-app/Program-net60.cs index f7b5459d0..4a48a94d7 100644 --- a/tests/DevApps/daemon-app/Daemon-app/Program-net60.cs +++ b/tests/DevApps/daemon-app/Daemon-app/Program-net60.cs @@ -47,7 +47,7 @@ static async Task Main(string[] args) // Get the token acquisition service ITokenAcquirerFactory tokenAcquirerFactory = app.Services.GetRequiredService(); var tokenAcquirer = tokenAcquirerFactory.GetTokenAcquirer(); - var result = await tokenAcquirer.GetTokenForAppAsync("api://a4c2469b-cf84-4145-8f5f-cb7bacf814bc/.default"); + var result = await tokenAcquirer.GetTokenForAppAsync("api://1e2fb196-50ce-4652-a4f9-26c1bf2e826b/.default"); Console.WriteLine($"Token expires on {result.ExpiresOn}"); #endif diff --git a/tests/DevApps/daemon-app/daemon-console-calling-downstreamApi/appsettings.json b/tests/DevApps/daemon-app/daemon-console-calling-downstreamApi/appsettings.json index 67b695ce7..07da6bbcd 100644 --- a/tests/DevApps/daemon-app/daemon-console-calling-downstreamApi/appsettings.json +++ b/tests/DevApps/daemon-app/daemon-console-calling-downstreamApi/appsettings.json @@ -16,6 +16,6 @@ "BaseUrl": "https://localhost:7060/", "RelativePath": "/WeatherForecast", "RequestAppToken": true, - "Scopes": [ "api://a4c2469b-cf84-4145-8f5f-cb7bacf814bc/.default" ] + "Scopes": [ "api://1e2fb196-50ce-4652-a4f9-26c1bf2e826b/.default" ] } } diff --git a/tests/DevApps/daemon-app/minimal-web-api/appsettings.json b/tests/DevApps/daemon-app/minimal-web-api/appsettings.json index 7c1681203..94cce6d19 100644 --- a/tests/DevApps/daemon-app/minimal-web-api/appsettings.json +++ b/tests/DevApps/daemon-app/minimal-web-api/appsettings.json @@ -2,7 +2,7 @@ "AzureAd": { "Instance": "https://login.microsoftonline.com/", "TenantId": "7f58f645-c190-4ce5-9de4-e2b7acd2a6ab", - "ClientId": "a4c2469b-cf84-4145-8f5f-cb7bacf814bc", + "ClientId": "1e2fb196-50ce-4652-a4f9-26c1bf2e826b", "Scopes": "Weather.All", "TokenDecryptionCredentials": [ ] diff --git a/tests/E2E Tests/TokenAcquirerTests/TokenAcquirer.cs b/tests/E2E Tests/TokenAcquirerTests/TokenAcquirer.cs index a4dcb8784..4a7111ac5 100644 --- a/tests/E2E Tests/TokenAcquirerTests/TokenAcquirer.cs +++ b/tests/E2E Tests/TokenAcquirerTests/TokenAcquirer.cs @@ -292,7 +292,7 @@ private static async Task CreateGraphClientAndAssert(TokenAcquirerFactory tokenA .GetAsync(o => o.Options .WithAppOnly() .WithAuthenticationScheme(s_optionName)); - Assert.True(users!=null && users.Value!=null && users.Value.Count >= 56); + Assert.True(users!=null && users.Value!=null && users.Value.Count >0); // Alternatively to calling Microsoft Graph, you can get a token acquirer service // and get a token, and use it in an SDK. diff --git a/tests/E2E Tests/WebAppUiTests/TestingWebAppLocally.cs b/tests/E2E Tests/WebAppUiTests/TestingWebAppLocally.cs index 5afbf8715..41cdd9e55 100644 --- a/tests/E2E Tests/WebAppUiTests/TestingWebAppLocally.cs +++ b/tests/E2E Tests/WebAppUiTests/TestingWebAppLocally.cs @@ -35,7 +35,7 @@ public TestingWebAppLocally(ITestOutputHelper output) _output = output; } - [Fact] + [Fact (Skip = "https://github.com/AzureAD/microsoft-identity-web/issues/2716")] [SupportedOSPlatform("windows")] public async Task ChallengeUser_MicrosoftIdFlow_LocalApp_ValidEmailPassword() { @@ -43,7 +43,7 @@ public async Task ChallengeUser_MicrosoftIdFlow_LocalApp_ValidEmailPassword() Process? process = null; const string TraceFileName = TraceFileClassName + "_ValidEmailPassword"; using IPlaywright playwright = await Playwright.CreateAsync(); - IBrowser browser = await playwright.Chromium.LaunchAsync(new() { Headless = true }); + IBrowser browser = await playwright.Chromium.LaunchAsync(new() { Headless = false }); IBrowserContext context = await browser.NewContextAsync(new BrowserNewContextOptions { IgnoreHTTPSErrors = true }); await context.Tracing.StartAsync(new() { Screenshots = true, Snapshots = true, Sources = true }); diff --git a/tests/E2E Tests/WebAppUiTests/WebAppCallsApiCallsGraphLocally.cs b/tests/E2E Tests/WebAppUiTests/WebAppCallsApiCallsGraphLocally.cs index eb0bde9ed..789607b48 100644 --- a/tests/E2E Tests/WebAppUiTests/WebAppCallsApiCallsGraphLocally.cs +++ b/tests/E2E Tests/WebAppUiTests/WebAppCallsApiCallsGraphLocally.cs @@ -38,7 +38,7 @@ public WebAppCallsApiCallsGraphLocally(ITestOutputHelper output) _output = output; } - [Fact] + [Fact(Skip = "https://github.com/AzureAD/microsoft-identity-web/issues/2716")] [SupportedOSPlatform("windows")] public async Task ChallengeUser_MicrosoftIdFlow_LocalApp_ValidEmailPasswordCreds_TodoAppFunctionsCorrectly() {