gerrithudsontrigger/src/test/java/com/sonyericsson/hudson/plugins/gerrit/trigger/hudsontrigger/actions/manual/ManualTriggerActionPermissionTest.java
/**
     * Tests if the html-link to {@link ManualTriggerAction#getUrlName()} is visible from the main-page.
     * It should be visible to Administrators as configured in the test-configuration.
     *
     * @throws Exception if so.
     */
Tests if the html-link to  ManualTriggerAction#getUrlName() is visible from the main-page.
It should be visible to Administrators as configured in the test-configuration.

@throws Exception if so.
Tests if the html - link to ManualTriggerAction#getUrlName () is visible from the main - page . It should be visible to Administrators as configured in the test - configuration . @throws Exception if so .
@LocalData
    public void testGetUrlName() throws Exception {
        ManualTriggerAction action = getManualTriggerAction();
        WebClient wc = new WebClient().login("admin", "admin");
        HtmlPage page = wc.goTo("/");
        try {
            HtmlAnchor a = page.getAnchorByHref(action.getUrlName());
            assertNotNull(a);
        } catch (ElementNotFoundException e) {
            fail("Admin should see the RootAction");
        }
    }
@ LocalData public void testGetUrlName ( ) throws Exception { ManualTriggerAction action = getManualTriggerAction ( ) ; WebClient wc = new WebClient ( ) . login ( "admin" , "admin" ) ; HtmlPage page = wc . goTo ( "/" ) ; try { HtmlAnchor a = page . getAnchorByHref ( action . getUrlName ( ) ) ; assertNotNull ( a ) ; } catch ( ElementNotFoundException e ) { fail ( "Admin should see the RootAction" ) ; } }
Tests if the html-link to {@link ManualTriggerAction#getUrlName()} is visible from the main-page.
Tests if the html - link to { @link ManualTriggerAction#getUrlName () } is visible from the main - page .