theappbusiness/TABTestKit

Add support for UIActivityViewController (share sheet)

Closed this issue · 0 comments

struct ActivitySheet: Element { 
	
	let id: String? = "ActivityListView"
	let type: XCUIElement.ElementType = .other
	
	var cancelButton: Button {
		if #available(iOS 13, *) {
			return Button(id: "Close", parent: self)
		} else {
			return Button(id: "Cancel") // On iOS 12, the cancel button sits outside the hierarchy for ActivityListView :(
		}
	}
	
}