add CLI, refactor acceptance tests