Travis: move back test into script section
refactor install and before_install to later be able to add caching support
for compiling NLOPT, JSON, Eigen