Added write concern for mongodb
Small changes to types
Added framework for basic encode/decode tests