Add all dependencies to run tests. Configure tests as composer task. Add tests to travis. Adjust code to make him exchangeable and testable.