aboutsummaryrefslogtreecommitdiff
path: root/plugins/base/src/test/kotlin/signatures/SignatureUtils.kt
diff options
context:
space:
mode:
Diffstat (limited to 'plugins/base/src/test/kotlin/signatures/SignatureUtils.kt')
-rw-r--r--plugins/base/src/test/kotlin/signatures/SignatureUtils.kt12
1 files changed, 12 insertions, 0 deletions
diff --git a/plugins/base/src/test/kotlin/signatures/SignatureUtils.kt b/plugins/base/src/test/kotlin/signatures/SignatureUtils.kt
new file mode 100644
index 00000000..e77b8757
--- /dev/null
+++ b/plugins/base/src/test/kotlin/signatures/SignatureUtils.kt
@@ -0,0 +1,12 @@
+package signatures
+
+import org.jsoup.Jsoup
+import org.jsoup.nodes.Element
+import utils.TestOutputWriter
+
+fun TestOutputWriter.renderedContent(path: String = "root/example.html") =
+ contents.getValue(path).let { Jsoup.parse(it) }.select("#content")
+ .single()
+
+fun Element.signature() = select("div.symbol.monospace")
+fun Element.firstSignature() = signature().first() \ No newline at end of file