diff --git a/tests/rustdoc-gui/docblock-code-block-line-number.goml b/tests/rustdoc-gui/docblock-code-block-line-number.goml index 53f756dfcd6..3c16626336e 100644 --- a/tests/rustdoc-gui/docblock-code-block-line-number.goml +++ b/tests/rustdoc-gui/docblock-code-block-line-number.goml @@ -87,8 +87,7 @@ assert-css: ("#settings", {"display": "block"}) // Then, click the toggle button. click: "input#line-numbers" -wait-for: 100 // FIXME: `wait-for-false` does not exist -assert-false: "pre.example-line-numbers" +wait-for-false: "pre.example-line-numbers" assert-local-storage: {"rustdoc-line-numbers": "false" } // Check that the rounded corners are back. @@ -107,8 +106,7 @@ assert-css: ( click: "input#line-numbers" wait-for: "pre.example-line-numbers" assert-local-storage: {"rustdoc-line-numbers": "true" } -wait-for: 100 // FIXME: `wait-for-false` does not exist -assert: "pre.example-line-numbers" +wait-for: "pre.example-line-numbers" // Same check with scraped examples line numbers. go-to: "file://" + |DOC_PATH| + "/scrape_examples/fn.test_many.html" @@ -195,15 +193,13 @@ define-function: ("check-line-numbers-existence", [], block { // Then, click the toggle button. click: "input#line-numbers" - wait-for: 100 // FIXME: `wait-for-false` does not exist - assert-local-storage-false: {"rustdoc-line-numbers": "true" } + wait-for-local-storage-false: {"rustdoc-line-numbers": "true" } assert-false: ".example-line-numbers" // Line numbers should still be there. assert: ".src-line-numbers" // Now disabling the setting. click: "input#line-numbers" - wait-for: 100 // FIXME: `wait-for-false` does not exist - assert-local-storage: {"rustdoc-line-numbers": "true" } + wait-for-local-storage: {"rustdoc-line-numbers": "true" } assert-false: ".example-line-numbers" // Line numbers should still be there. assert: ".src-line-numbers" @@ -246,12 +242,10 @@ wait-for: "#settings" // Then, click the toggle button. click: "input#line-numbers" -wait-for: 100 // FIXME: `wait-for-false` does not exist +wait-for-count: (".example-wrap > pre.example-line-numbers", 0) assert-local-storage-false: {"rustdoc-line-numbers": "true" } -assert-count: (".example-wrap > pre.example-line-numbers", 0) // Now turning off the setting. click: "input#line-numbers" -wait-for: 100 // FIXME: `wait-for-false` does not exist +wait-for-count: (".example-wrap > pre.example-line-numbers", 2) assert-local-storage: {"rustdoc-line-numbers": "true" } -assert-count: (".example-wrap > pre.example-line-numbers", 2)