aboutsummaryrefslogtreecommitdiff
path: root/test/src/model/PropertyTest.kt
diff options
context:
space:
mode:
authorDmitry Jemerov <intelliyole@gmail.com>2015-01-12 16:06:54 +0100
committerDmitry Jemerov <intelliyole@gmail.com>2015-01-12 16:06:54 +0100
commit49feb9021ca24150257caac4a62af5628f52b6b5 (patch)
treee5b53761a5338b9931bfe6969cbee988596ec28e /test/src/model/PropertyTest.kt
parent5f47bc17630ef1457b36054dc8b19011d9d14132 (diff)
parent23af5e2540aca25ab64deec1821a069f827d7c77 (diff)
downloaddokka-49feb9021ca24150257caac4a62af5628f52b6b5.tar.gz
dokka-49feb9021ca24150257caac4a62af5628f52b6b5.tar.bz2
dokka-49feb9021ca24150257caac4a62af5628f52b6b5.zip
Merge pull request #9 from orangy/annotations
Support annotation classes and annotations in model and rendered output
Diffstat (limited to 'test/src/model/PropertyTest.kt')
-rw-r--r--test/src/model/PropertyTest.kt26
1 files changed, 26 insertions, 0 deletions
diff --git a/test/src/model/PropertyTest.kt b/test/src/model/PropertyTest.kt
index 103da170..14c43f78 100644
--- a/test/src/model/PropertyTest.kt
+++ b/test/src/model/PropertyTest.kt
@@ -99,4 +99,30 @@ public class PropertyTest {
}
}
}
+
+ Test fun annotatedProperty() {
+ verifyModel("test/data/properties/annotatedProperty.kt") { model ->
+ with(model.members.single().members.single()) {
+ assertEquals(1, annotations.count())
+ with(annotations[0]) {
+ assertEquals("inline", name)
+ assertEquals(Content.Empty, content)
+ assertEquals(DocumentationNode.Kind.Annotation, kind)
+ }
+ }
+ }
+ }
+
+ Test fun propertyWithReceiver() {
+ verifyModel("test/data/properties/propertyWithReceiver.kt") { model ->
+ with(model.members.single().members.single()) {
+ assertEquals("String", name)
+ assertEquals(DocumentationNode.Kind.ExternalClass, kind)
+ with(members.single()) {
+ assertEquals("foobar", name)
+ assertEquals(DocumentationNode.Kind.Property, kind)
+ }
+ }
+ }
+ }
}