-
Notifications
You must be signed in to change notification settings - Fork 218
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
Jennyf/ui web app #556
Jennyf/ui web app #556
Conversation
ChromeOptions options = new ChromeOptions(); | ||
// ~2x faster, no visual rendering | ||
// comment-out below when debugging to see the UI automation | ||
options.AddArguments(TestConstants.Headless); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
comment line 27 to see the UI.
// comment-out below when debugging to see the UI automation | ||
options.AddArguments(TestConstants.Headless); | ||
IWebDriver driver = new ChromeDriver(options); | ||
driver.Manage().Timeouts().ImplicitWait = TimeSpan.FromSeconds(10); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this is an implicit wait, so if the elements are taking longer to appear, we won't move to the next element and throw an error. we can adjust this, right now, it's pretty fast.
|
||
// Assert | ||
Assert.Contains(labResponse.User.Upn, driver.PageSource); | ||
Assert.Contains(TestConstants.PhotoLabel, driver.PageSource); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
other ideas for asserts are welcome, but if we signed in correctly & called graph, we get the upn appearing and the photo label for graph.
UserInformationFieldIds fields) | ||
{ | ||
// Lab user needs to be a guest in the msidentity-samples-testing tenant | ||
Trace.WriteLine(string.Format("Logging in ... Entering user name: {0}", user.Upn)); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
the lab user has to be a guest in msidentity-samples-testing (hence the comment), so printing out the lab user that's default, in case it changes. right now it's idlab1 from msidlab4. the default user should not change.
|
||
using Microsoft.Identity.Web.Test.Common; | ||
|
||
namespace Microsoft.Identity.Web.Test.LabInfrastructure |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
modified version from MSAL. they have to check ADFS & B2C. we can add B2C later, so should be easy to expand this class when needed.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM.
Shouln't you also have and additional file in this PR? tests\WebAppCallsMicrosoftGraph\Properties\ServiceDependencies\webAppTestMsIdWeb - Web Deploy\profile.arm.json ?
lol. yes. i forgot those. thank you. In reply to: 483939173 [](ancestors = 483939173) |
No description provided.