Skip to content

Commit eb28ade

Browse files
committed
Ported to using <footer> tag.
HTML5 migration.
1 parent 6b6f1cf commit eb28ade

File tree

3 files changed

+16
-4
lines changed

3 files changed

+16
-4
lines changed
Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
<div id="footer">
1+
<footer>
22
&copy;
33
<a href="mailto:<spring:message code="t_site_author_email" />" title="<spring:message code="t_write_email" />"><spring:message code="t_site_author_name" /></a>, 2009-2012
4-
</div>
4+
</footer>

src/main/webapp/WEB-INF/static/styles/main.css

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ body,
2424
width: 20%;
2525
}
2626

27-
#footer {
27+
footer {
2828
background-color: #f5f5f5;
2929
text-align: right;
3030
border-top: dotted 1px;

src/test/java/ru/mystamps/web/tests/page/AbstractPage.java

Lines changed: 13 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -129,7 +129,7 @@ public String getHeader() {
129129
}
130130

131131
public boolean footerExists() {
132-
return elementWithIdExists("footer");
132+
return elementWithTagNameExists("footer");
133133
}
134134

135135
public boolean linkWithLabelExists(final String label) {
@@ -224,6 +224,18 @@ protected boolean elementWithXPathExists(final String xpath) {
224224
return el != null;
225225
}
226226

227+
protected boolean elementWithTagNameExists(final String tagName) {
228+
WebElement el = null;
229+
230+
try {
231+
el = getElementByTagName(tagName);
232+
} catch (final NoSuchElementException ex) {
233+
return false;
234+
}
235+
236+
return el != null;
237+
}
238+
227239
protected WebElement getLinkByText(final String linkText) {
228240
try {
229241
return driver.findElement(By.linkText(linkText));

0 commit comments

Comments
 (0)