Skip to content

Commit b5c3072

Browse files
committed
fixed issues
1 parent 4654a53 commit b5c3072

2 files changed

Lines changed: 9 additions & 1 deletion

File tree

src/main/java/com/ultimecia/http/HttpRequest.java

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,14 @@ public HttpMethod getMethod() {
1414
return method;
1515
}
1616

17+
public String getOriginalHttpVersion() {
18+
return originalHttpVersion;
19+
}
20+
21+
public HttpVersion getBestCompatibleHttpVersion() {
22+
return bestCompatiableHttpVersion;
23+
}
24+
1725
void setMethod(String methodName) throws HttpParsingException {
1826
for(HttpMethod method:HttpMethod.values()){
1927
if(methodName.equals(method.name())){

src/test/java/com/ultimecia/http/HttpparserTest.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -118,7 +118,7 @@ void parseHttpRequestUnsupportedHttpVersion() {
118118
);
119119
fail();
120120
} catch (HttpParsingException e) {
121-
assertEquals(e.getErrorCode(), HttpStatusCodes.SERVER_ERROR_505_HTTP_VERSION_NOT_SUPPORTED);
121+
assertEquals(e.getErrorCode(), HttpStatusCodes.SERVER_ERROR_505_VERSION_NOT_SUPPORTED);
122122
}
123123
}
124124

0 commit comments

Comments
 (0)