From c075c9570777d0946ba48ad88171379b52733416 Mon Sep 17 00:00:00 2001 From: Denis Ambatenne <75973078+d-ambatenne@users.noreply.github.com> Date: Thu, 6 Jul 2023 14:46:12 +0200 Subject: HTML: fix of redundant dot and related autotest (#2289) (#3057) * HTML: fix of redundant dot and related autotest (#2289) * Update plugins/base/src/test/kotlin/renderers/html/SearchbarDataInstallerTest.kt Change after the PR #3057 review Co-authored-by: Ignat Beresnev * Change after the PR #3057 review Co-authored-by: Ignat Beresnev --------- Co-authored-by: Denis Ambatenne Co-authored-by: Ignat Beresnev --- plugins/base/src/test/kotlin/utils/HtmlUtils.kt | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'plugins/base/src/test/kotlin/utils') diff --git a/plugins/base/src/test/kotlin/utils/HtmlUtils.kt b/plugins/base/src/test/kotlin/utils/HtmlUtils.kt index bfba882a..0748d91a 100644 --- a/plugins/base/src/test/kotlin/utils/HtmlUtils.kt +++ b/plugins/base/src/test/kotlin/utils/HtmlUtils.kt @@ -1,11 +1,16 @@ package utils +import com.fasterxml.jackson.module.kotlin.jacksonObjectMapper +import com.fasterxml.jackson.module.kotlin.readValue +import org.jetbrains.dokka.base.renderers.html.SearchRecord import org.jsoup.Jsoup import org.jsoup.nodes.Element import org.jsoup.select.Elements internal fun TestOutputWriter.navigationHtml(): Element = contents.getValue("navigation.html").let { Jsoup.parse(it) } +internal fun TestOutputWriter.pagesJson(): List = jacksonObjectMapper().readValue(contents.getValue("scripts/pages.json")) + internal fun Elements.selectNavigationGrid(): Element { return this.select("div.overview").select("span.nav-link-grid").single() } -- cgit