Skip to content

E2e tests #535

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 19 commits into from
Sep 2, 2020
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 9 additions & 3 deletions tests/IntegrationTests/IntegrationTestService/Startup.cs
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@
using Microsoft.Extensions.Configuration;
using Microsoft.Extensions.DependencyInjection;
using Microsoft.Extensions.Hosting;
using Microsoft.Identity.Client;
using Microsoft.Identity.Web;
using Microsoft.Identity.Web.Test.Common;
using Microsoft.Identity.Web.Test.LabInfrastructure;
Expand All @@ -27,14 +28,19 @@ public Startup(IConfiguration configuration)
public void ConfigureServices(IServiceCollection services)
{
_keyVault = new KeyVaultSecretsProvider();
string ccaSecret = _keyVault.GetSecret(TestConstants.OBOClientKeyVaultUri).Value;

services.AddAuthentication(JwtBearerDefaults.AuthenticationScheme)
.AddMicrosoftIdentityWebApi(Configuration, subscribeToJwtBearerMiddlewareDiagnosticsEvents: true)
.EnableTokenAcquisitionToCallDownstreamApi()
.AddInMemoryTokenCaches();
services.Configure<MicrosoftIdentityOptions>(options =>
{
options.ClientSecret = _keyVault.GetSecret(TestConstants.OBOClientKeyVaultUri).Value;
services.Configure<MicrosoftIdentityOptions>(options =>
{
options.ClientSecret = ccaSecret;
});
services.Configure<ConfidentialClientApplicationOptions>(options =>
{
options.ClientSecret = ccaSecret;
});
services.AddRazorPages(options =>
{
Expand Down