Use travis ci for testing

Rebased the #410 to `dev` branch