aboutsummaryrefslogtreecommitdiff
path: root/integration-tests/maven/projects
diff options
context:
space:
mode:
Diffstat (limited to 'integration-tests/maven/projects')
-rw-r--r--integration-tests/maven/projects/it-maven/pom.xml11
-rw-r--r--integration-tests/maven/projects/it-maven/src/main/kotlin/it/basic/PublicClass.kt9
-rw-r--r--integration-tests/maven/projects/it-maven/src/main/kotlin/it/internal/InternalClass.kt7
-rw-r--r--integration-tests/maven/projects/it-maven/src/main/kotlin/it/overriddenVisibility/VisiblePrivateClass.kt12
-rw-r--r--integration-tests/maven/projects/it-maven/src/main/kotlin/it/protected/ProtectedClass.kt10
5 files changed, 49 insertions, 0 deletions
diff --git a/integration-tests/maven/projects/it-maven/pom.xml b/integration-tests/maven/projects/it-maven/pom.xml
index cfc8ba66..23f6548f 100644
--- a/integration-tests/maven/projects/it-maven/pom.xml
+++ b/integration-tests/maven/projects/it-maven/pom.xml
@@ -117,6 +117,10 @@
<dir>${project.basedir}/src/main/java</dir>
</sourceDirectories>
+ <documentedVisibilities>
+ <visibility>PUBLIC</visibility>
+ <visibility>PROTECTED</visibility>
+ </documentedVisibilities>
<!-- Disable linking to online kotlin-stdlib documentation -->
<noStdlibLink>false</noStdlibLink>
@@ -138,6 +142,13 @@
<reportUndocumented>true</reportUndocumented>
<includeNonPublic>false</includeNonPublic>
</packageOptions>
+
+ <packageOptions>
+ <matchingRegex>it.overriddenVisibility.*</matchingRegex>
+ <documentedVisibilities>
+ <visibility>PRIVATE</visibility>
+ </documentedVisibilities>
+ </packageOptions>
</perPackageOptions>
<pluginsConfiguration>
<org.jetbrains.dokka.base.DokkaBase>
diff --git a/integration-tests/maven/projects/it-maven/src/main/kotlin/it/basic/PublicClass.kt b/integration-tests/maven/projects/it-maven/src/main/kotlin/it/basic/PublicClass.kt
index 71bc7e63..d7a72392 100644
--- a/integration-tests/maven/projects/it-maven/src/main/kotlin/it/basic/PublicClass.kt
+++ b/integration-tests/maven/projects/it-maven/src/main/kotlin/it/basic/PublicClass.kt
@@ -2,6 +2,9 @@
package it.basic
+/**
+ * §PUBLIC§ (marker for asserts)
+ */
class PublicClass {
/**
* This function is public and documented
@@ -24,6 +27,12 @@ class PublicClass {
private fun privateUndocumentedFunction(): String = ""
+ /**
+ * This function is protected and documented
+ */
+ protected fun protectedDocumentedFunction(): String = ""
+
+ protected fun protectedUndocumentedFunction(): String = ""
/**
* This property is public and documented
diff --git a/integration-tests/maven/projects/it-maven/src/main/kotlin/it/internal/InternalClass.kt b/integration-tests/maven/projects/it-maven/src/main/kotlin/it/internal/InternalClass.kt
new file mode 100644
index 00000000..6173d239
--- /dev/null
+++ b/integration-tests/maven/projects/it-maven/src/main/kotlin/it/internal/InternalClass.kt
@@ -0,0 +1,7 @@
+package it.internal
+
+/**
+ * §INTERNAL§ (marker for asserts)
+ * This class is internal and should not be rendered
+ */
+internal class InternalClass
diff --git a/integration-tests/maven/projects/it-maven/src/main/kotlin/it/overriddenVisibility/VisiblePrivateClass.kt b/integration-tests/maven/projects/it-maven/src/main/kotlin/it/overriddenVisibility/VisiblePrivateClass.kt
new file mode 100644
index 00000000..230f5e0b
--- /dev/null
+++ b/integration-tests/maven/projects/it-maven/src/main/kotlin/it/overriddenVisibility/VisiblePrivateClass.kt
@@ -0,0 +1,12 @@
+package it.overriddenVisibility
+
+/**
+ * Private classes and methods generally should not be visible, but [documentedVisibilities]
+ * are overriden for this specific package to include private code
+ *
+ * §PRIVATE§ (marker for asserts)
+ */
+private class VisiblePrivateClass {
+ private val privateVal: Int = 0
+ private fun privateMethod() {}
+} \ No newline at end of file
diff --git a/integration-tests/maven/projects/it-maven/src/main/kotlin/it/protected/ProtectedClass.kt b/integration-tests/maven/projects/it-maven/src/main/kotlin/it/protected/ProtectedClass.kt
new file mode 100644
index 00000000..ad19f1a1
--- /dev/null
+++ b/integration-tests/maven/projects/it-maven/src/main/kotlin/it/protected/ProtectedClass.kt
@@ -0,0 +1,10 @@
+package it.protected
+
+/**
+ * Protected class should be visible because it's included in documentedVisibilities
+ *
+ * §PROTECTED§ (marker for asserts)
+ */
+protected class ProtectedClass {
+ protected fun protectedFun(): String = "protected"
+}