@@ -73,7 +73,7 @@ private void doSetup()
7373 public void testShortUrl () throws Exception
7474 {
7575 String shortUrl = nextUrlKey ();
76- String targetUrl = buildRelativeUrl ("project" , getProjectName (), "begin" );
76+ String targetUrl = WebTestHelper . getContextPath () + buildRelativeUrl ("project" , getProjectName (), "begin" );
7777
7878 ShortUrlAdminPage adminPage = ShortUrlAdminPage .beginAt (this );
7979 adminPage .createNewShortUrl (shortUrl , targetUrl );
@@ -95,7 +95,7 @@ public void testShortUrl() throws Exception
9595 });
9696
9797 log ("Update shortUrl target" );
98- String updatedTargetUrl = buildRelativeUrl ("project" , "home" , "begin" );
98+ String updatedTargetUrl = WebTestHelper . getContextPath () + buildRelativeUrl ("project" , "home" , "begin" );
9999
100100 adminPage = ShortUrlAdminPage .beginAt (this );
101101 adminPage .createNewShortUrl (shortUrl , updatedTargetUrl );
@@ -149,7 +149,7 @@ public void testTrickyCharacters() throws Exception
149149 assertEquals ("Row count with filter" , 1 , drt .getDataRowCount ());
150150
151151 String shortUrl = nextUrlKey ();
152- String targetUrl = getCurrentRelativeURL ();
152+ String targetUrl = WebTestHelper . getContextPath () + getCurrentRelativeURL ();
153153
154154 ShortUrlAdminPage adminPage = ShortUrlAdminPage .beginAt (this );
155155 adminPage .createNewShortUrl (shortUrl , targetUrl );
0 commit comments