Package org.rendersnake.tools

Examples of org.rendersnake.tools.Inspector


    }
    private class Content implements Renderable {
      public void renderOn(HtmlCanvas html) throws IOException {
       
            html.render(new Inspector(new Logo()));
            html.hr();
            html.render(new Inspector(new InspectThis()));
            html.hr();
            html.render(new Inspector(new MenuBar("here")));
            html.hr();
            html.render(new Inspector(new Sidebar()));
            html.hr();
            html.render(new Inspector(new GotoTop()));
            html.hr();
            html.render(new Inspector(new SourceLink()));
            html.hr();
            html.render(new Inspector(new TranslatorForm()));
            html.hr();
            html.render(new Inspector(new CityTable()));
            html.hr();
    }
View Full Code Here


public class InspectorTest extends TestCase {

    public void testInpsectPersonUI() throws IOException {
        PersonUI ui = new PersonUI(new Person());
        Inspector inspector = new Inspector(ui);
        HtmlCanvas html = new HtmlCanvas();
        html.render(inspector);
        assertNotNull("inspected html", html.toHtml());
        System.out.println(html.toHtml());
        assertTrue(html.toHtml().indexOf("<div class=\"rendersnake-inspector\">") == 0);
View Full Code Here

        System.out.println(html.toHtml());
        assertTrue(html.toHtml().indexOf("<div class=\"rendersnake-inspector\">") == 0);
    }
    public void testInpsectNull() throws IOException {
        try {
            new Inspector(null);
            fail("new Inspector(null) must raise illegal argument exception");
        } catch (IllegalArgumentException iae) {
            // got it
        }
    }   
View Full Code Here

        }
    } 
    public void testRender() throws Exception {
        HtmlCanvas html = new HtmlCanvas();
        ctx.renderForErrorOn(html);
        ctx.renderForInpectorOn(new Inspector(new PersonalPage()), html);
        assertFalse(html.toHtml().length() == 0);
    }
View Full Code Here

        }
    } 
    public void testRender() throws Exception {
        HtmlCanvas html = new HtmlCanvas();
        ctx.renderForErrorOn(html);
        ctx.renderForInpectorOn(new Inspector(new PersonalPage()), html);
        assertFalse(html.toHtml().length() == 0);
    }
View Full Code Here

TOP

Related Classes of org.rendersnake.tools.Inspector

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.