"border-bottom-width: 1px; "+
"text-align: center; width: 100%'/>" +
"<div style='margin-bottom: 2px'/>";
HorizontalRuleEmulator emulator =
new HorizontalRuleEmulatorWithBorderStylingOnMultipleDivs();
/**
* Test no style applied
*/
DOMOutputBuffer domOutputBuffer = new DOMOutputBuffer() ;
emulator.emulateHorizontalRule(domOutputBuffer,
createHorizontalRuleAttributes(null));
assertEquals("Incorrect Hr Emulation",noStyle_Expected,
helper.render(domOutputBuffer.getRoot()));
/**
* Test width style applied
*/
domOutputBuffer = new DOMOutputBuffer() ;
emulator.emulateHorizontalRule(domOutputBuffer,
createHorizontalRuleAttributes("width: 50%"));
assertEquals("Incorrect Hr Emulation",widthStyle_Expected,
helper.render(domOutputBuffer.getRoot()));
/**
* Test height style applied
*/
domOutputBuffer = new DOMOutputBuffer() ;
emulator.emulateHorizontalRule(domOutputBuffer,
createHorizontalRuleAttributes("height: 5px"));
assertEquals("Incorrect Hr Emulation",heightStyle_Expected,
helper.render(domOutputBuffer.getRoot()));
/**
* Test colour style applied
*/
domOutputBuffer = new DOMOutputBuffer() ;
emulator.emulateHorizontalRule(domOutputBuffer,
createHorizontalRuleAttributes("color: red"));
assertEquals("Incorrect Hr Emulation",colorStyle_Expected,
helper.render(domOutputBuffer.getRoot()));