Get browser tests working

In preparation for gutting the innards and replacing it with a
more idiomatic Buffer (and possibly Stream) interface. But I need
to be sure compatibility is maintained when I package it all up
with browserify.