-
Notifications
You must be signed in to change notification settings - Fork 0
mulka/majd
Folders and files
Name | Name | Last commit message | Last commit date | |
---|---|---|---|---|
Repository files navigation
MAJD - My Awesome JSON Debugger NOTE: I built this, and it was useful to me for a while. But, I realized there are a lot of situations in testing where you want an actual programming language to write tests with and can't get away with just sending static input and comparing expected output exactly. So, I would recommend using something else for testing, but I'll leave this here in case it is useful to anyone. MAJD is a utility used to test a JSON API. The kind of JSON API it supports right now is where you do an HTTP POST with a JSON document as the body of the request. Then, the server responds with another JSON document as the response body. Different methods are specified via URL. To use, run test.py on the command line. It will run through all the tests in the tests directory. If the tests pass, this will output nothing. As soon as one fails, it will stop and display the error. The tests directory should contain the tests you want to run. As an example, look at main.json which contains a single JSON array with one method call per position in the array. MAJD will POST the input JSON to the URL constructed using the method name. It will then will run a smart JSON diff between the actual output and the expected output. If the two don't match, MAJD will stop and report an error.
About
My Awesome JSON Debugger
Resources
Stars
Watchers
Forks
Releases
No releases published
Packages 0
No packages published