Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
runcon
Plantuml Server
Commits
e4128699
Commit
e4128699
authored
Jul 10, 2013
by
Maxime Sinclair
Browse files
[TASK] No more used method getServerUrl suppressed
parent
ce168633
Changes
1
Hide whitespace changes
Inline
Side-by-side
src/test/java/net/sourceforge/plantuml/servlet/TestUtils.java
View file @
e4128699
...
...
@@ -7,32 +7,20 @@ import com.meterware.httpunit.*;
*/
public
class
TestUtils
{
/**
* Return the URL of the PlantUMLServlet, deployed on the testing web server in the following form
* http://server/contextroot/ Note the trailing slash (/)
*
* @return the URL
*/
public
static
String
getServerUrl
()
{
return
"http://localhost/plantuml/"
;
}
/**
* Try getting a response for the given Conversation and Request show an error message if a 404 error appears
*
* @param conversation
* - the conversation to use
* @param conversation The conversation to use
* @param request
* @return the response
* @throws an
* Exception if getting the response fails
* @return The response
* @throws nfe If getting the response fails
*/
public
static
WebResponse
tryGetResponse
(
WebConversation
conversation
,
WebRequest
request
)
throws
Exception
{
WebResponse
response
=
null
;
try
{
response
=
conversation
.
getResponse
(
request
);
}
catch
(
HttpNotFoundException
nfe
)
{
System
.
err
.
println
(
"The URL '"
+
request
.
getURL
()
+
"' is no
t
active
any more
"
);
System
.
err
.
println
(
"The URL '"
+
request
.
getURL
()
+
"' is no
more
active"
);
throw
nfe
;
}
return
response
;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment