GroupCommerce/sdk.php — pull request #35 by jacobangel (2012-06-04 18:17:00+00:00)
Title: Moving tests to PHPUnit and adding BroadcastApi.php

_Ch-ch-ch-ch-changes_
____________
### Testing
Two big changes here: First off, I'm adding automated testing using phpunit (I guess they're more integration tests though?). When properly installed, you can simply run `phpunit` from the root directory, and then tests will pass.

This also enables us to use a pre-commit hook like [this one](https://gist.github.com/975252) to check any modifications made to the PHP sdk. (For those unfamiliar: this means that git will basically not let you commit if you don't fix the tests/code.)

### BroadcastApi
This was not a ton of code (it's essentially a stripped down version of the PublisherApi), but I thought we really should have some form of broadcast api, even if it's potentially a bit too heavy weight for practical use.
____________
### Questions & Comments
- Next up for testing is probably the WebRequest.php and the various caching objects.
- I'm a bit at a loss for how to test the POST requests, as they tend to actually modify data rather than just blankly returning data, and our API rejects requests with improper verbs.
- What else should we write test for?

### Reviewers
@andrewglenn
@JoeCianflone
@statichippo