4 writes to Id
Microsoft.AspNetCore.Identity.Test (4)
SignInManagerTest.cs (3)
1033
var user = new PocoUser {
Id
= "foo", UserName = "Foo" };
1064
var user = new PocoUser {
Id
= "foo", UserName = "Foo" };
1095
var user = new PocoUser {
Id
= "foo", UserName = "Foo" };
src\Identity\test\Shared\PocoModel\PocoUser.cs (1)
16
Id
= Guid.NewGuid().ToString();
42 references to Id
Microsoft.AspNetCore.Identity.Test (42)
NoopUserStore.cs (1)
10
return Task.FromResult(user.
Id
);
SecurityStampValidatorTest.cs (8)
79
id.AddClaim(new Claim(ClaimTypes.NameIdentifier, user.
Id
));
112
id.AddClaim(new Claim(ClaimTypes.NameIdentifier, user.
Id
));
139
id.AddClaim(new Claim(ClaimTypes.NameIdentifier, user.
Id
));
180
tid.AddClaim(new Claim(ClaimTypes.NameIdentifier, user.
Id
));
221
id.AddClaim(new Claim(ClaimTypes.NameIdentifier, user.
Id
));
258
id.AddClaim(new Claim(ClaimTypes.NameIdentifier, user.
Id
));
296
id.AddClaim(new Claim(ClaimTypes.NameIdentifier, user.
Id
));
325
userManager.Setup(u => u.GetUserIdAsync(user)).ReturnsAsync(user.
Id
).Verifiable();
SignInManagerTest.cs (28)
94
manager.Setup(m => m.FindByIdAsync(user.
Id
)).ReturnsAsync(user);
95
manager.Setup(m => m.GetUserIdAsync(user)).ReturnsAsync(user.
Id
.ToString());
128
SetupSignIn(context, auth, user.
Id
, isPersistent, loginProvider: null, amr: "pwd");
152
SetupSignIn(context, auth, user.
Id
, false, loginProvider: null, amr: "pwd");
215
id.AddClaim(new Claim(ClaimTypes.Name, user.
Id
));
284
It.Is<ClaimsPrincipal>(id => id.FindFirstValue(ClaimTypes.Name) == user.
Id
),
323
SetupSignIn(context, auth, user.
Id
, false, loginProvider);
328
It.Is<ClaimsPrincipal>(id => id.FindFirstValue(ClaimTypes.Name) == user.
Id
),
373
var id = SignInManager<PocoUser>.StoreTwoFactorInfo(user.
Id
, null);
374
SetupSignIn(context, auth, user.
Id
, isPersistent);
381
It.Is<ClaimsPrincipal>(i => i.FindFirstValue(ClaimTypes.Name) == user.
Id
415
var id = SignInManager<PocoUser>.StoreTwoFactorInfo(user.
Id
, null);
454
var id = SignInManager<PocoUser>.StoreTwoFactorInfo(user.
Id
, null);
530
var id = SignInManager<PocoUser>.StoreTwoFactorInfo(user.
Id
, externalLogin ? loginProvider : null);
536
&& i.FindFirstValue(ClaimTypes.NameIdentifier) == user.
Id
),
543
SetupSignIn(context, auth, user.
Id
);
579
SetupSignIn(context, auth, user.
Id
, isPersistent, loginProvider);
673
var id = SignInManager<PocoUser>.StoreTwoFactorInfo(user.
Id
, externalLogin ? loginProvider : null);
680
&& i.FindFirstValue(ClaimTypes.NameIdentifier) == user.
Id
),
689
SetupSignIn(context, auth, user.
Id
, isPersistent, null, "mfa");
695
It.Is<ClaimsPrincipal>(i => i.FindFirstValue(ClaimTypes.Name) == user.
Id
733
var id = SignInManager<PocoUser>.StoreTwoFactorInfo(user.
Id
, loginProvider: null);
759
It.Is<ClaimsPrincipal>(i => i.FindFirstValue(ClaimTypes.Name) == user.
Id
791
id.AddClaim(new Claim(ClaimTypes.Name, user.
Id
));
946
SetupSignIn(context, auth, user.
Id
, isPersistent: null, loginProvider: null, amr: "pwd");
1000
SetupSignIn(context, auth, user.
Id
, isPersistent: null, loginProvider: null, amr: "pwd");
1200
var id = SignInManager<PocoUser>.StoreTwoFactorInfo(user.
Id
, null);
1266
var id = SignInManager<PocoUser>.StoreTwoFactorInfo(user.
Id
, null);
UserClaimsPrincipalFactoryTest.cs (2)
49
userManager.Setup(m => m.GetUserIdAsync(user)).ReturnsAsync(user.
Id
);
98
Assert.Contains(claims, c => c.Type == manager.Options.ClaimsIdentity.UserIdClaimType && c.Value == user.
Id
);
UserManagerTest.cs (3)
209
store.Setup(s => s.FindByIdAsync(user.
Id
, CancellationToken.None)).Returns(Task.FromResult(user)).Verifiable();
213
var result = await userManager.FindByIdAsync(user.
Id
);
1763
.Returns(Task.FromResult(user2.
Id
))