What tools do you use to test your public REST API

2019-01-08 06:15发布

问题:

Looking for tools use to test REST API.

So far I'm only aware of SoapUI. I've tried SOAPUI but - at least in a mac - it's terrible.

Wondering what people are using to test their own APIs.

回答1:

If you're just testing your APIs manually, we've found RestClient 2.3 or the Poster add-on for Firefox to be pretty helpful. Both of these let you build requests that GET, PUT, POST, or DELETE. You can save these requests to rerun later.

For simple automated testing try the Linux (or Cygwin) 'curl' command in a shell script.

From something more industrial strength you can move up to Apache JMeter. JMeter is great for load testing.

31 October 2014: HTTPRequester is now a better choice for Firefox.

July 2015: Postman is a good choice for Chrome



回答2:

Postman in the chrome store is simple but powerful.



回答3:

I use http://hurl.it/

Ha. Sorry, I mis-read your post. I've used cucumber to test it before. It worked out nicely.



回答4:

We are using Groovy to test our RestFUL API, using a series of helper functions to build the xml put/post/gets and then a series of tests on the nodes of the XML to check that the data is manipulated correctly.

We use Poster (for Firefox, Chrome seems to be lacking a similar tool) for hand testing single areas, or simply to poll the API at times when we need to create further tests, or check the status of things.



回答5:

We're planning to use FitNesse, with the RestFixture. We haven't started writing our tests yet, our newest tester got things up and running last week, however he has used FitNesse for this in his last company, so we know it's a reasonable setup for what we want to do.

More info available here: http://smartrics.blogspot.com/2008/08/get-fitnesse-with-some-rest.html



回答6:

I am using Fiddler - this is a great tool and allows you to quickly hack on previous http request amending headers / content etc.

Apart from that I am using scipts written in Python (using httplib) , as this is one of the easiest way to create integration test.



回答7:

I am using DevHttpClient Plugin for chrome, its handy. it does also saves previous actions. clean UI as well



回答8:

http://www.quadrillian.com/ this enables you to create an entire test suite for your API and run it from your browser and share it with others.



回答9:

We use Groovy and Spock for writing highly expressive BDD style tests. Unbeatable combo! Jersey Client API or HttpClient is used for handling the HTTP requests.

For manual/acceptance testing we use Curl or Chrome apps as Postman or Dev HTTP Client.



回答10:

We test our own with our own unit tests and oftentimes a dedicated client app.



回答11:

There is a free tool from theRightAPI that lets you test any HTTP based API. It also lets you save and share your test scenarios.

www.theRightAPI.com/test