diff options
Diffstat (limited to 'test')
-rw-r--r-- | test/data/format/inheritedExtensions.kt | 11 | ||||
-rw-r--r-- | test/data/format/inheritedExtensions.md | 21 | ||||
-rw-r--r-- | test/src/format/MarkdownFormatTest.kt | 6 |
3 files changed, 38 insertions, 0 deletions
diff --git a/test/data/format/inheritedExtensions.kt b/test/data/format/inheritedExtensions.kt new file mode 100644 index 00000000..e38fe00d --- /dev/null +++ b/test/data/format/inheritedExtensions.kt @@ -0,0 +1,11 @@ +open class Foo + +class Bar : Foo() + +fun Foo.first() { + +} + +fun Bar.second() { + +} diff --git a/test/data/format/inheritedExtensions.md b/test/data/format/inheritedExtensions.md new file mode 100644 index 00000000..79137eac --- /dev/null +++ b/test/data/format/inheritedExtensions.md @@ -0,0 +1,21 @@ +[test](test/index) / [Bar](test/-bar/index) + + +# Bar + +`class Bar : [Foo](test/-foo/index)` + + + +### Constructors + + +| [<init>](test/-bar/-init-) | `Bar()` | + + +### Extension Functions + + +| [first](test/first) | `fun [Foo](test/-foo/index).first(): Unit` | +| [second](test/second) | `fun [Bar](test/-bar/index).second(): Unit` | + diff --git a/test/src/format/MarkdownFormatTest.kt b/test/src/format/MarkdownFormatTest.kt index 728ce20f..bb61fa1c 100644 --- a/test/src/format/MarkdownFormatTest.kt +++ b/test/src/format/MarkdownFormatTest.kt @@ -209,4 +209,10 @@ public class MarkdownFormatTest { markdownService.appendNodes(tempLocation, output, model.members.single().members.filter { it.name == "Bar" }) } } + + @Test fun inheritedExtensions() { + verifyOutput("test/data/format/inheritedExtensions.kt", ".md") { model, output -> + markdownService.appendNodes(tempLocation, output, model.members.single().members.filter { it.name == "Bar" }) + } + } } |