Skip to content

Commit 69cf097

Browse files
committed
sourcekitd/test: add an interface grouping test for user module.
1 parent 441c85f commit 69cf097

File tree

2 files changed

+20
-0
lines changed

2 files changed

+20
-0
lines changed
Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
{
2+
"A": [
3+
"swift_mod.swift",
4+
],
5+
"B": [
6+
"swift_mod_syn.swift",
7+
]
8+
}
Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
// RUN: %empty-directory(%t.mod)
2+
// RUN: %target-swift-frontend -module-name MyModule -emit-module -emit-module-path %t.mod/MyModule.swiftmodule -emit-module-doc -emit-module-doc-path %t.mod/MyModule.swiftdoc -group-info-path %S/Inputs/group.json %S/Inputs/swift_mod.swift %S/Inputs/swift_mod_syn.swift
3+
// RUN: %sourcekitd-test -req=interface-gen -module MyModule -group-name A -- -I %t.mod | %FileCheck -check-prefix=GROUPA %s
4+
// RUN: %sourcekitd-test -req=interface-gen -module MyModule -group-name B -- -I %t.mod | %FileCheck -check-prefix=GROUPB %s
5+
6+
// GROUPA: MyClass
7+
// GROUPA-NOT: P1
8+
// GROUPA-NOT: P2
9+
10+
// GROUPB: P1
11+
// GROUPB: P2
12+
// GROUPB-NOT: MyClass

0 commit comments

Comments
 (0)