Refactored tests, wrote tests, added CI config file.

This branch adds some tests to the lib/ subdirectory, and makes tests discoverable by most tools.
I will continue to write more tests covering the basic lib/ (at first) to make sure further code changes and refactorings do not break the bitcoin/crypto layer.

To test, simply run "nosetests lib" from the root of the checkout, or "trial lib" (depending on what your favorite test runner is).

Furthermore, this adds a travis config file, so travis CI can easily pick up changes and run unit tests automagically.