Skip to content
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.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions .github/workflows/functional-test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ jobs:
test_targets:
# iOS
- HOST_OS: 'xcode-27'
XCODE_VERSION: '27.0-beta'
XCODE_VERSION: '27.0'
PLATFORM_NAME: 'iOS'
PLATFORM_VERSION: '27.0'
DEVICE_NAME: 'iPhone 17'
Expand All @@ -42,7 +42,7 @@ jobs:

# tvOS
- HOST_OS: 'xcode-27'
XCODE_VERSION: '27.0-beta'
XCODE_VERSION: '27.0'
PLATFORM_NAME: 'tvOS'
PLATFORM_VERSION: '27.0'
DEVICE_NAME: 'Apple TV 4K (3rd generation)'
Expand All @@ -54,7 +54,7 @@ jobs:

# WatchOS
- HOST_OS: 'xcode-27'
XCODE_VERSION: '27.0-beta'
XCODE_VERSION: '27.0'
PLATFORM_NAME: 'watchOS'
PLATFORM_VERSION: '27.0'
DEVICE_NAME: 'Apple Watch Series 11 (46mm)'
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/wda-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ env:
MIN_IPHONE_DEVICE_NAME: "iPhone 16"
MIN_IPAD_DEVICE_NAME: "iPad Air 13-inch (M2)"
MAX_VM_IMAGE: xcode-27
MAX_XCODE_VERSION: "27.0-beta"
MAX_XCODE_VERSION: "27.0"
MAX_PLATFORM_VERSION: "27.0"
MAX_TV_PLATFORM_VERSION: "27.0"
MAX_IPHONE_DEVICE_NAME: "iPhone 17"
Expand Down
4 changes: 4 additions & 0 deletions WebDriverAgent.xcodeproj/project.pbxproj
Original file line number Diff line number Diff line change
Expand Up @@ -1332,6 +1332,7 @@
FBCAFE000000000000006035 /* FBAudioCaptureCommands.m in Sources */ = {isa = PBXBuildFile; fileRef = FBCAFE000000000000006031 /* FBAudioCaptureCommands.m */; };
FBCAFE000000000000006042 /* FBExtAudioPipeline.m in Sources */ = {isa = PBXBuildFile; fileRef = FBCAFE000000000000006041 /* FBExtAudioPipeline.m */; };
FBCAFE000000000000006051 /* FBAudioStreamTests.m in Sources */ = {isa = PBXBuildFile; fileRef = FBCAFE000000000000006050 /* FBAudioStreamTests.m */; };
FBCAFE000000000000008051 /* FBBroadcastLabelsTests.m in Sources */ = {isa = PBXBuildFile; fileRef = FBCAFE000000000000008050 /* FBBroadcastLabelsTests.m */; };
FBCAFE000000000000007002 /* FBSocks5TunnelProtocol.h in Headers */ = {isa = PBXBuildFile; fileRef = FBCAFE000000000000007000 /* FBSocks5TunnelProtocol.h */; };
FBCAFE000000000000007003 /* FBSocks5TunnelProtocol.h in Headers */ = {isa = PBXBuildFile; fileRef = FBCAFE000000000000007000 /* FBSocks5TunnelProtocol.h */; };
FBCAFE000000000000007004 /* FBSocks5TunnelProtocol.m in Sources */ = {isa = PBXBuildFile; fileRef = FBCAFE000000000000007001 /* FBSocks5TunnelProtocol.m */; };
Expand Down Expand Up @@ -2109,6 +2110,7 @@
FBCAFE000000000000006040 /* FBExtAudioPipeline.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = FBExtAudioPipeline.h; sourceTree = "<group>"; };
FBCAFE000000000000006041 /* FBExtAudioPipeline.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = FBExtAudioPipeline.m; sourceTree = "<group>"; };
FBCAFE000000000000006050 /* FBAudioStreamTests.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = FBAudioStreamTests.m; sourceTree = "<group>"; };
FBCAFE000000000000008050 /* FBBroadcastLabelsTests.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = FBBroadcastLabelsTests.m; sourceTree = "<group>"; };
FBCAFE000000000000007000 /* FBSocks5TunnelProtocol.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = FBSocks5TunnelProtocol.h; sourceTree = "<group>"; };
FBCAFE000000000000007001 /* FBSocks5TunnelProtocol.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = FBSocks5TunnelProtocol.m; sourceTree = "<group>"; };
FBCAFE000000000000007010 /* FBSocks5URI.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = FBSocks5URI.h; sourceTree = "<group>"; };
Expand Down Expand Up @@ -2955,6 +2957,7 @@
FBCAFE00000000000000001B /* FBVideoEncoderTests.m */,
FBCAFE000000000000004001 /* FBVideoStreamSessionTests.m */,
FBCAFE000000000000006050 /* FBAudioStreamTests.m */,
FBCAFE000000000000008050 /* FBBroadcastLabelsTests.m */,
FBCAFE000000000000002001 /* FBImageUtilsTests.m */,
);
path = UnitTests;
Expand Down Expand Up @@ -5272,6 +5275,7 @@
FBCAFE00000000000000001C /* FBVideoEncoderTests.m in Sources */,
FBCAFE000000000000004002 /* FBVideoStreamSessionTests.m in Sources */,
FBCAFE000000000000006051 /* FBAudioStreamTests.m in Sources */,
FBCAFE000000000000008051 /* FBBroadcastLabelsTests.m in Sources */,
FBCAFE000000000000002002 /* FBImageUtilsTests.m in Sources */,
);
runOnlyForDeploymentPostprocessing = 0;
Expand Down
27 changes: 21 additions & 6 deletions WebDriverAgentLib/Utilities/FBBroadcastManager.h
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,18 @@ typedef NS_ERROR_ENUM(FBBroadcastManagerErrorDomain, FBBroadcastManagerError) {
/** YES while the broadcast extension is connected to the control server. */
@property (nonatomic, readonly) BOOL isExtensionConnected;

/**
Every localized variant ReplayKit ships for one of its UI strings, e.g.
"CONTROL_CENTER_START_BROADCAST" ("Start Broadcast", "Übertragung starten", ...). The device's
preferred localizations come first; the set covers all languages so that matching does not
depend on which language the system UI is currently rendered in. Resolved from the ReplayKit
framework's own localization tables once per key and cached.

@param key The key in ReplayKit's Localizable strings table
@return The distinct non-empty labels, or an empty array when ReplayKit or the key is unavailable
*/
+ (NSArray<NSString *> *)replayKitLabelsForKey:(NSString *)key;

/** Starts the loopback control server. Safe to call multiple times. */
- (void)startListening;

Expand All @@ -54,14 +66,16 @@ typedef NS_ERROR_ENUM(FBBroadcastManagerErrorDomain, FBBroadcastManagerError) {
for the extension to connect. Must be called on the main thread. Idempotent while connected.

@param timeout The overall time budget in seconds for the broadcast to reach the connected state
@param confirmButtonLabels Labels to look for on the system confirmation sheet
@param confirmButtonLabels Extra labels to look for on the system confirmation sheet, in
addition to the "Start Broadcast" label in every language ReplayKit is localized for
@param dismissButtonLabels Labels for dismissing the system's stale "Screen Broadcasting" alert
that SpringBoard posts whenever a broadcast ends, which otherwise blocks the picker dance from
completing. Defaults to ["OK"] when empty/nil
completing. Added to the alert's "OK" label in every language ReplayKit is localized for
@param goToApplicationButtonLabels Labels for the alert's other button. Together with
dismissButtonLabels this anchors the alert's identity: it is only treated as the Screen
Broadcasting alert, and auto-dismissed, when one button matches dismissButtonLabels and the
other matches this list. Defaults to ["Go to Application"] when empty/nil
other matches this list. Added to the alert's "Go to Application" label in every language
ReplayKit is localized for
@param restoreForegroundApp YES to re-activate the previously active application afterwards
@param error If there is an error, upon return contains an NSError describing the problem
@return NO in case of a failure
Expand Down Expand Up @@ -89,12 +103,13 @@ typedef NS_ERROR_ENUM(FBBroadcastManagerErrorDomain, FBBroadcastManagerError) {
best-effort attempt to dismiss the system's stale "Screen Broadcasting" alert that SpringBoard
posts once the broadcast ends. Idempotent when no broadcast is running.

@param dismissButtonLabels Labels for dismissing the system's stale "Screen Broadcasting" alert.
Defaults to ["OK"] when empty/nil
@param dismissButtonLabels Extra labels for dismissing the system's stale "Screen Broadcasting"
alert, added to its "OK" label in every language ReplayKit is localized for
@param goToApplicationButtonLabels Labels for the alert's other button. Together with
dismissButtonLabels this anchors the alert's identity: it is only treated as the Screen
Broadcasting alert, and auto-dismissed, when one button matches dismissButtonLabels and the
other matches this list. Defaults to ["Go to Application"] when empty/nil
other matches this list. Added to the alert's "Go to Application" label in every language
ReplayKit is localized for
@param error If there is an error, upon return contains an NSError describing the problem
@return NO in case of a failure. The alert-dismissal attempt is best-effort and never causes
this to return NO by itself
Expand Down
Loading
Loading