Search in sources :

Example 6 with GroovyPagesUriSupport

use of org.grails.web.pages.GroovyPagesUriSupport in project grails-core by grails.

the class GroovyPagesUriSupportTests method testNoSuffxGetViewURI.

public void testNoSuffxGetViewURI() {
    GroovyPagesUriSupport uriSupport = new GroovyPagesUriSupport();
    assertEquals("/foo/bar", uriSupport.getNoSuffixViewURI("foo", "bar"));
    assertEquals("/bar/foo", uriSupport.getNoSuffixViewURI("foo", "/bar/foo"));
    assertEquals("/foo/bar/foo", uriSupport.getNoSuffixViewURI("foo", "bar/foo"));
}
Also used : GroovyPagesUriSupport(org.grails.web.pages.GroovyPagesUriSupport)

Example 7 with GroovyPagesUriSupport

use of org.grails.web.pages.GroovyPagesUriSupport in project grails-core by grails.

the class GroovyPagesUriSupportTests method testGetViewURI.

public void testGetViewURI() {
    GroovyPagesUriSupport uriSupport = new GroovyPagesUriSupport();
    assertEquals("/foo/bar.gsp", uriSupport.getViewURI("foo", "bar"));
    assertEquals("/bar/foo.gsp", uriSupport.getViewURI("foo", "/bar/foo"));
    assertEquals("/foo/bar/foo.gsp", uriSupport.getViewURI("foo", "bar/foo"));
}
Also used : GroovyPagesUriSupport(org.grails.web.pages.GroovyPagesUriSupport)

Aggregations

GroovyPagesUriSupport (org.grails.web.pages.GroovyPagesUriSupport)7 GroovyClassLoader (groovy.lang.GroovyClassLoader)3 GroovyObject (groovy.lang.GroovyObject)3