adding sbt + refactoring for flatspec