public void testBot() throws Exception { AttributesImpl attributes = new AttributesImpl(); attributes.addAttribute(null, "name", null, "String", "bot.predicate1"); handler.startElement(null, null, "bot", attributes); Bot expected = new Bot("bot.predicate1"); Bot actual = (Bot) stack.peek(); assertEquals(expected, actual); Bot bot2 = new Bot("bot.predicate2"); assertFalse(bot2.equals(actual)); }