aboutsummaryrefslogtreecommitdiff
path: root/plugins/base/base-test-utils/src/main/kotlin/renderers/SignatureUtils.kt
blob: e77b8757e0f4eb6105dc32c82ce4800218f99c31 (plain)
1
2
3
4
5
6
7
8
9
10
11
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()