File tree 5 files changed +12
-8
lines changed
main/java/ru/mystamps/web/controller 5 files changed +12
-8
lines changed Original file line number Diff line number Diff line change 30
30
@ Controller
31
31
public class TestController {
32
32
33
- @ GetMapping ("/test/invalid/response-404" )
34
- public void notFound (HttpServletResponse response ) throws IOException {
35
- response .sendError (HttpServletResponse .SC_NOT_FOUND );
36
- }
37
-
38
33
@ GetMapping ("/test/invalid/empty-jpeg-file" )
39
34
public void emptyJpegFile (HttpServletResponse response ) {
40
35
response .setContentType ("image/jpeg" );
Original file line number Diff line number Diff line change @@ -35,7 +35,7 @@ Add image with URL with invalid response
35
35
Element Text Should Be id=image-url.errors Could not download file
36
36
37
37
Add image with URL to a file that does not exist
38
- Input Text id=image-url ${SITE_URL } /test/invalid /response-404
38
+ Input Text id=image-url ${MOCK_SERVER } /series /response-404
39
39
Submit Form id=add-image-form
40
40
Element Text Should Be id=image-url.errors File not found
41
41
Original file line number Diff line number Diff line change @@ -52,7 +52,7 @@ Create series with image URL with invalid response
52
52
Element Text Should Be id=image-url.errors Could not download file
53
53
54
54
Create series with image URL to a file that does not exist
55
- Input Text id=image-url ${SITE_URL } /test/invalid /response-404
55
+ Input Text id=image-url ${MOCK_SERVER } /series /response-404
56
56
Submit Form id=add-series-form
57
57
Element Text Should Be id=image-url.errors File not found
58
58
Original file line number Diff line number Diff line change @@ -139,7 +139,7 @@ Import series and series sale with a new seller from an external site
139
139
Element Should Be Disabled id=seller-url
140
140
141
141
Submit a request that will fail to download a file
142
- Input Text id=url ${SITE_URL } /test/invalid /response-404
142
+ Input Text id=url ${MOCK_SERVER } /series /response-404
143
143
Submit Form id=import-series-form
144
144
Element Text Should Be id=request-status DownloadingFailed
145
145
Original file line number Diff line number Diff line change
1
+ {
2
+ "request" : {
3
+ "method" : " GET" ,
4
+ "url" : " /series/response-404"
5
+ },
6
+ "response" : {
7
+ "status" : 404
8
+ }
9
+ }
You can’t perform that action at this time.
0 commit comments