Make test work for more Gradle versions