From cf33010c49097411f8b56248b5a5bc2b6c19c7d9 Mon Sep 17 00:00:00 2001 From: Holly Borla Date: Mon, 23 Aug 2021 10:02:47 -0700 Subject: [PATCH] [Test] Remove test/Constraints/trailing_closures_objc.swift. This test has been XFAIL'd for over a year due to changes in AVFoundation. The second error message in this test also recently changed due to changes in Foundation. The diagnostics here are not reliable because they can change when new overloads are added to the SDK. --- test/Constraints/trailing_closures_objc.swift | 30 ------------------- 1 file changed, 30 deletions(-) delete mode 100644 test/Constraints/trailing_closures_objc.swift diff --git a/test/Constraints/trailing_closures_objc.swift b/test/Constraints/trailing_closures_objc.swift deleted file mode 100644 index 8cd35f535f5fc..0000000000000 --- a/test/Constraints/trailing_closures_objc.swift +++ /dev/null @@ -1,30 +0,0 @@ -// RUN: %target-typecheck-verify-swift - -// REQUIRES: rdar66110025 -// REQUIRES: objc_interop -// REQUIRES: OS=macosx - -import Foundation -import AVFoundation -import AppKit - -func foo(options: [AVMediaSelectionOption]) { - let menuItems: [NSMenuItem] = options.map { (option: AVMediaSelectionOption) in - NSMenuItem(title: option.displayName, action: #selector(NSViewController.respondToMediaOptionSelection(from:)), keyEquivalent: "") - // expected-error@-1 {{type 'NSViewController' has no member 'respondToMediaOptionSelection(from:)'}} - } -} - -func rdar28004686(a: [IndexPath]) { - _ = a.sorted { (lhs: NSIndexPath, rhs: NSIndexPath) -> Bool in true } - // expected-error@-1 {{cannot convert value of type '(NSIndexPath, NSIndexPath) -> Bool' to expected argument type '(IndexPath, IndexPath) throws -> Bool'}} -} - -class Test: NSObject { - var categories : NSArray? - func rdar28012273() { - let categories = ["hello", "world"] - self.categories = categories.sorted { $0.localizedCaseInsensitiveCompare($1) == ComparisonResult.orderedDescending } - // expected-error@-1 {{cannot assign value of type '[String]' to type 'NSArray'}} {{121-121= as NSArray}} - } -}