I'm new to httpunit, and having a problem issuing an HTTP DELETE request. Here's a snippet
private WebResponse httpDelete(String destination) throws Exception
WebConversation wc = new WebConversation();
HeaderOnlyWebRequest req = new GetMethodWebRequest(destination);
System.out.println("Method before: " + req.getMethod());
System.out.println("Method after: " + req.getMethod());
The console shows GET as the method both before and after the call to setMethod, and the server sees a GET when the getResponse is issued, so it's not just a problem reporting the method. My company's policy towards OS s/w prevents me from examining the source… any help gratefully received.
BTW, my first thought was to change the relevant line to:
HeaderOnlyWebRequest req = new HeaderOnlyWebRequest (destination);
…but the HeaderOnlyWebRequest constructors are protected.
Oops - should have posted the above to Help, I suppose :(
Sign up for the SourceForge newsletter:
You seem to have CSS turned off.
Please don't fill out this field.