Testing the translation of "Go to random page"

The new test fails since the "Go to random page" button is not yet
internationalized.
This commit is contained in:
Veloman Yunkan 2022-01-30 21:44:44 +04:00 committed by Matthieu Gautier
parent 3da81a3d0f
commit 527a606281
1 changed files with 9 additions and 1 deletions

View File

@ -537,6 +537,10 @@ std::string TestContentIn404HtmlResponse::taskbarLinks() const
? "Դեպի '" + bookTitle + "'֊ի գլխավոր էջը"
: "Go to the main page of '" + bookTitle + "'";
const std::string goToRandomPage = isTranslatedVersion()
? "Բացել պատահական էջ"
: "Go to a randomly selected page";
return R"(<a id="kiwix_serve_taskbar_home_button" title=")"
+ goToMainPageOfBook
+ R"(" aria-label=")"
@ -546,7 +550,11 @@ std::string TestContentIn404HtmlResponse::taskbarLinks() const
+ R"(/"><button>)"
+ bookTitle
+ R"(</button></a>
<a id="kiwix_serve_taskbar_random_button" title="Go to a randomly selected page" aria-label="Go to a randomly selected page"
<a id="kiwix_serve_taskbar_random_button" title=")"
+ goToRandomPage
+ R"(" aria-label=")"
+ goToRandomPage
+ R"("
href="/ROOT/random?content=)"
+ bookName
+ R"("><button>&#x1F3B2;</button></a>)";