mirror of
https://github.com/apple/swift.git
synced 2025-12-14 20:36:38 +01:00
21 lines
536 B
Swift
21 lines
536 B
Swift
// RUN: %target-run-simple-swift
|
|
// REQUIRES: executable_test
|
|
// REQUIRES: objc_interop
|
|
|
|
import StdlibUnittest
|
|
import Foundation
|
|
|
|
let conformanceUniquingTests = TestSuite("ConformanceUniquing")
|
|
|
|
func isSimpleSetAlgebra<T: SetAlgebra>(_: T.Type) -> Bool {
|
|
return T.self == T.Element.self
|
|
}
|
|
|
|
// rdar://problem/46685973
|
|
conformanceUniquingTests.test("Nested types with the same name") {
|
|
expectTrue(isSimpleSetAlgebra(NSData.WritingOptions.self))
|
|
expectTrue(isSimpleSetAlgebra(JSONSerialization.WritingOptions.self))
|
|
}
|
|
|
|
runAllTests()
|