fix Junit test for V3.9 and issue #2305

Fix Junit test for V3.9 where setChunked was not correctly setup in the
request.
Adding it and adding LAST_CHUNK correct the JUnit test.