diff options
Diffstat (limited to 'test')
-rw-r--r-- | test/data/format/crossLanguage/kotlinExtendsJava/Bar.html | 11 | ||||
-rw-r--r-- | test/data/format/inheritedMembers.kt | 12 | ||||
-rw-r--r-- | test/data/format/inheritedMembers.md | 38 | ||||
-rw-r--r-- | test/src/format/MarkdownFormatTest.kt | 6 |
4 files changed, 67 insertions, 0 deletions
diff --git a/test/data/format/crossLanguage/kotlinExtendsJava/Bar.html b/test/data/format/crossLanguage/kotlinExtendsJava/Bar.html index 5b93d837..e7b139d8 100644 --- a/test/data/format/crossLanguage/kotlinExtendsJava/Bar.html +++ b/test/data/format/crossLanguage/kotlinExtendsJava/Bar.html @@ -22,5 +22,16 @@ </tr> </tbody> </table> +<h3>Inherited Functions</h3> +<table> +<tbody> +<tr> +<td> +<a href="test/test/-foo/xyzzy">xyzzy</a></td> +<td> +<code><span class="keyword">open</span> <span class="keyword">fun </span><span class="identifier">xyzzy</span><span class="symbol">(</span><span class="symbol">)</span><span class="symbol">: </span><span class="identifier">Unit</span></code></td> +</tr> +</tbody> +</table> </BODY> </HTML> diff --git a/test/data/format/inheritedMembers.kt b/test/data/format/inheritedMembers.kt new file mode 100644 index 00000000..2d0c4ca1 --- /dev/null +++ b/test/data/format/inheritedMembers.kt @@ -0,0 +1,12 @@ +open class Foo { + fun first() { + } + + val firstProp: Int = 0 +} + +class Bar : Foo() { + fun second() + + val secondProp: Int = 1 +} diff --git a/test/data/format/inheritedMembers.md b/test/data/format/inheritedMembers.md new file mode 100644 index 00000000..d58d3974 --- /dev/null +++ b/test/data/format/inheritedMembers.md @@ -0,0 +1,38 @@ +[test](test/index) / [Bar](test/-bar/index) + + +# Bar + +`class Bar : [Foo](test/-foo/index)` + + + +### Constructors + + +| [<init>](test/-bar/-init-) | `Bar()` | + + +### Properties + + +| [secondProp](test/-bar/second-prop) | `val secondProp: Int` | + + +### Inherited Properties + + +| [firstProp](test/-foo/first-prop) | `val firstProp: Int` | + + +### Functions + + +| [second](test/-bar/second) | `fun second(): Unit` | + + +### Inherited Functions + + +| [first](test/-foo/first) | `fun first(): Unit` | + diff --git a/test/src/format/MarkdownFormatTest.kt b/test/src/format/MarkdownFormatTest.kt index ab905c18..728ce20f 100644 --- a/test/src/format/MarkdownFormatTest.kt +++ b/test/src/format/MarkdownFormatTest.kt @@ -203,4 +203,10 @@ public class MarkdownFormatTest { markdownService.appendNodes(tempLocation, output, model.members.single().members) } } + + @Test fun inheritedMembers() { + verifyOutput("test/data/format/inheritedMembers.kt", ".md") { model, output -> + markdownService.appendNodes(tempLocation, output, model.members.single().members.filter { it.name == "Bar" }) + } + } } |