Skip to content

Commit b7df342

Browse files
committed
[Test] Add a test for rdar://problem/46685973
1 parent cacd72f commit b7df342

File tree

1 file changed

+20
-0
lines changed

1 file changed

+20
-0
lines changed
Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
// RUN: %target-run-simple-swift
2+
// REQUIRES: executable_test
3+
// REQUIRES: objc_interop
4+
5+
import StdlibUnittest
6+
import Foundation
7+
8+
let conformanceUniquingTests = TestSuite("ConformanceUniquing")
9+
10+
func isSimpleSetAlgebra<T: SetAlgebra>(_: T.Type) -> Bool {
11+
return T.self == T.Element.self
12+
}
13+
14+
// rdar://problem/46685973
15+
conformanceUniquingTests.test("Nested types with the same name") {
16+
expectTrue(isSimpleSetAlgebra(NSData.WritingOptions.self))
17+
expectTrue(isSimpleSetAlgebra(JSONSerialization.WritingOptions.self))
18+
}
19+
20+
runAllTests()

0 commit comments

Comments
 (0)