Skip to content
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

Kaisong1990/update automation device version #1445

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
Expand Up @@ -46,6 +46,17 @@
BlueprintName = "InteractiveiOSTests"
ReferencedContainer = "container:MSAL.xcodeproj">
</BuildableReference>
<SkippedTests>
<Test
Identifier = "MSALPingUITests/testInteractivePingLogin_withConvergedApp_withPromptAlways_withLoginHint_andPassedInWebView">
</Test>
<Test
Identifier = "MSALPingUITests/testInteractivePingLogin_withConvergedApp_withPromptAlways_withLoginHint_andSystemWebView">
</Test>
<Test
Identifier = "MSALPingUITests/testInteractivePingLogin_withNonConvergedApp_withPromptAlways_noLoginHint_andEmbeddedWebView">
</Test>
</SkippedTests>
</TestableReference>
<TestableReference
skipped = "NO">
Expand Down
1 change: 1 addition & 0 deletions MSAL/src/public/MSAL.h
Expand Up @@ -87,3 +87,4 @@ FOUNDATION_EXPORT const unsigned char MSAL__Framework_VersionString[];
#import <MSAL/MSALAuthenticationSchemePop.h>

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This pull request does not update CHANGELOG.md.

Please consider if this change would be noticeable to a partner or user and either update CHANGELOG.md or resolve this conversation.

#import <MSAL/MSALAuthenticationSchemeProtocol.h>
#import <MSAL/MSALHttpMethod.h>
#import <MSAL/MSALWipeCacheForAllAccountsConfig.h>
11 changes: 10 additions & 1 deletion MSAL/test/automation/tests/MSALBaseUITest.m
Expand Up @@ -374,7 +374,16 @@ - (void)closeAuthUIUsingWebViewType:(MSIDWebviewType)webViewType
buttonTitle = @"Done";
}

[self.testApp.buttons[buttonTitle] msidTap];
XCUIElementQuery *elementQuery = [self.testApp.buttons matchingIdentifier:buttonTitle];
if(elementQuery.count > 1)
{
// We take the second one and tap it
XCUIElement *secondButton = [elementQuery elementBoundByIndex:1];
[secondButton msidTap];
} else
{
[self.testApp.buttons[buttonTitle] msidTap];
}
}

- (void)closeResultView
Expand Down
6 changes: 3 additions & 3 deletions azure_pipelines/automation.yml
Expand Up @@ -74,7 +74,7 @@ jobs:
-workspace MSAL.xcworkspace \
-scheme "MSAL Test Automation (iOS)" \
-sdk iphonesimulator \
-destination 'platform=iOS Simulator,name=iPhone 12,OS=15.0' \
-destination 'platform=iOS Simulator,name=iPhone 12,OS=15.2' \
-derivedDataPath 'build' \
| tee xcodebuild.log \
| xcpretty -c
Expand All @@ -86,8 +86,8 @@ jobs:
script: |
ls build/Build/Products/
xcodebuild test-without-building \
-xctestrun 'build/Build/Products/MSAL Test Automation (iOS)_iphonesimulator15.0-x86_64.xctestrun' \
-destination 'platform=iOS Simulator,name=iPhone 12,OS=15.0' \
-xctestrun 'build/Build/Products/MSAL Test Automation (iOS)_iphonesimulator15.2-x86_64.xctestrun' \
-destination 'platform=iOS Simulator,name=iPhone 12,OS=15.2' \
-retry-tests-on-failure \
-parallel-testing-enabled NO \
-resultBundlePath '$(Agent.BuildDirectory)/s/test_output/report.xcresult'
Expand Down