[ApiAuthorization] Make test more reliable (#7092)
This commit is contained in:
parent
29898df8a8
commit
8958bdee2e
|
|
@ -1,4 +1,4 @@
|
|||
// Copyright (c) .NET Foundation. All rights reserved.
|
||||
// Copyright (c) .NET Foundation. All rights reserved.
|
||||
// Licensed under the Apache License, Version 2.0. See License.txt in the project root for license information.
|
||||
|
||||
using System.Linq;
|
||||
|
|
@ -67,10 +67,10 @@ namespace Microsoft.AspNetCore.ApiAuthorization.IdentityServer.Configuration
|
|||
|
||||
// Assert
|
||||
var spaClient = Assert.Single(options.Clients, c => c.ClientId == "TestSPA");
|
||||
Assert.Equal(new[] { "openid", "profile", "ResourceAPI" }, spaClient.AllowedScopes.OrderBy(id => id).ToArray());
|
||||
Assert.Equal(new[] { "openid", "profile", "ResourceAPI" }.OrderBy(id => id).ToArray(), spaClient.AllowedScopes.OrderBy(id => id).ToArray());
|
||||
|
||||
var nativeApp = Assert.Single(options.Clients, c => c.ClientId == "NativeApp");
|
||||
Assert.Equal(new[] { "offline_access", "openid", "profile", "ResourceAPI" }, nativeApp.AllowedScopes.OrderBy(id => id).ToArray());
|
||||
Assert.Equal(new[] { "offline_access", "openid", "profile", "ResourceAPI" }.OrderBy(id => id).ToArray(), nativeApp.AllowedScopes.OrderBy(id => id).ToArray());
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue