use of elemental2.dom.Document in project tapestry-5 by apache.
the class HeadTest method display.
@Test
public void display() {
tester = new PageTester(TestConstants.APP2_PACKAGE, TestConstants.APP2_NAME);
Document doc = tester.renderPage("TestPageForHead");
assertTrue(doc.toString().contains("OK"));
}
use of elemental2.dom.Document in project tapestry-5 by apache.
the class LocaleTest method prefer_canada_french.
@Test
public void prefer_canada_french() {
tester.setPreferedLanguage(Locale.CANADA_FRENCH);
Document doc = tester.renderPage("TestPageForLocale");
assertEquals(doc.getElementById("id1").getChildMarkup(), "French page");
}
use of elemental2.dom.Document in project tapestry-5 by apache.
the class LocaleTest method change_language_in_browser.
@Test
public void change_language_in_browser() {
tester.setPreferedLanguage(Locale.ENGLISH);
Document doc = tester.renderPage("TestPageForLocale");
assertEquals(doc.getElementById("id1").getChildMarkup(), "English page");
tester.setPreferedLanguage(Locale.CANADA_FRENCH);
doc = tester.renderPage("TestPageForLocale");
assertEquals(doc.getElementById("id1").getChildMarkup(), "French page");
}
use of elemental2.dom.Document in project tapestry-5 by apache.
the class LocaleTest method no_preferred_language.
@Test
public void no_preferred_language() {
Document doc = tester.renderPage("TestPageForLocale");
assertEquals(doc.getElementById("id1").getChildMarkup(), "English page");
}
use of elemental2.dom.Document in project tapestry-5 by apache.
the class ASOTest method submit_aso.
@Test
public void submit_aso() {
tester = new PageTester(TestConstants.APP2_PACKAGE, TestConstants.APP2_NAME);
Document doc = tester.renderPage("TestPageForASO");
assertTrue(doc.toString().contains("bar"));
}
Aggregations