Making sure to check if we have an active output
buffer before trying to grab its contents, especially
for PHP-fpm, since `fastcgi_finish_request()` closes
all output buffers automatically

This fixes #163
Merge branch 'bugfix/output-buffer-level-checking'

Fixes #163
Fix tests that fail on HHVM due to inconsistencies with Zend on key()

https://github.com/facebook/hhvm/blob/master/hphp/doc/inconsistencies#L23

HHVM does not reset the internal array cursor when an array is copied. Zend 5.5
does, so when an array is passed to a function (like `$sample_data` in the fixed
tests) the internal cursor is reset. For 5.6 the maintainers have specified that
how the internal cursor is copied is an implementation detail and may change without
warning. So it's best to be explicit and not rely on key() or current() at all.

I just fixed the tests for which this causes problems on HHVM as part of the effort
to get klein.php to 100% for HHVM.
Fix nits: obj->id instead of obj->{"id"}
Fix reference to Response::file() method in README

Fixes issue #207.
Merge pull request #208 from eimajenthat/patch-1

Fix reference to Response::file() method in README
New test to verify the failing behavior
The `abort()` method now throws an HttpException
Moved the try/catch block of the `dispatch()` method
and now re-throwing the HttpException in `handleRouteCallback()`
Merge pull request #217 from Rican7/bugfix/abort-code-http-error-inconsistency

Bugfix - Abort code HTTP error inconsistency
Now catching any other exceptions in the `dispatch()` method
Removing the now unnecessary exception catching in
the `handleRouteCallback()` method. It should now bubble up to the
`dispatch()` method
Passing our previous exception to our default error
handler's `UnhandledException`.
Updating our test for the more proper behavior
Expanding our tests for `abort()` coverage
Merge pull request #218 from Rican7/feature/exception-catching-simplification

Feature - Exception catching simplification
New exception for when a route's path fails to compile
New test to make sure that an invalid route would
throw an exception
New method to validate regular expressions and now
checking them in the `compileRoute()` method
Fleshed out the RoutePathCompilationException to
contain a useful message and a reference to the route object