added test for buffers, also changed the way I check for the existence of Buffer that works in v8 and spidermonkey in couchdb