Error

Error:(22, 0) Could not find method android() for arguments [build_9wglzemmdwpqh4v6gkig07116$_run_closure3@565f363a] on root project 'ApplicationTest' of type org.gradle.api.Project.

Solution

delete: compileSdkVersion 'Google Inc.:Google APIs:17' in build.gradle