@Test public void testAltAttribute() throws Exception { l.setAlt("Some text"); assertEquals("Some text", l.getAlt()); assertEquals("Some text", l.getAttribute("alt")); l.setAlt(null); assertEquals("", l.getAttribute("alt")); assertNull(l.getAlt()); l.setAttribute("alt", "Some text"); assertEquals("Some text", l.getAlt()); assertEquals("Some text", l.getAttribute("alt")); l.setAttribute("alt", null); assertEquals("", l.getAttribute("alt")); assertNull(l.getAlt()); }