Firefox plugins to simulate POST
Today I was developing a servlet filter that would handle specific POST requests. Everything was fine until I had to test my code. I have never written a single line of JUnit test and I thought I didn’t need to now.
First I just filtered out GET requests and filtered these based on parameters. Then I needed to separate POST and GET requests and figured maybe some cool Firefox plugin would let me play around with request method. I found two. UrlParams seemed good. I was able to make a GET request with some parameters and then move those params to POST part and create another (now POST) request. It has various options to move data between GET and POST. Looks pretty neat but has some flaws.
- Has export but no import. It would be great if I could save my valuable request info and use it again some other time.
- Sidebar was always visible. It’s just a little annoyance. I could of been done in Firebug way where the extra area in window is hidden if I move to some other tab. After a while it started to disturb me. But fortunately after closing and reopening the sidebar the request parameters did not disappear.
Second plugin I tried was Tamper Data. It sounded at first like it could do something like I need but it couldn’t. Or at least for me the user interface was too overwhelming. I could monitor site traffic and request data with it but not simulate it. You can see the results here.
So I think I’m going to write some JUnit. Could be handy later in my project
If anyone finds out a better solution please let me know.