Feature/block test

This add multiple tests to `Block.js`, removes legacy code in it, and fix some small issues in utility functions and browser compatibility.

After this PR, the test coverage is ~60% for bitcore, 93% for Block.js.