make build work with new IntelliJ IDEA 13.1 API and make all tests pass