• After 15+ years, we've made a big change: Android Forums is now Early Bird Club. Learn more here.

Gradle DSL method not found: 'testImplementation()' when creating a separate test module

mcpixel

Newbie
I do according to this instruction:https://developer.android.com/studio/test#use_separate_test_modules_for_instrumented_tests
After I replaced apply plugin: 'com.android.library' with apply plugin: 'com.android.test' I got this error:
Code:
ERROR: Gradle DSL method not found: 'testImplementation()'
Possible causes:
The project 'app5' may be using a version of the Android Gradle plug-in that does not contain the method (e.g. 'testCompile' was added in 1.1.0).
Upgrade plugin to version 3.4.2 and sync project

The project 'app5' may be using a version of Gradle that does not contain the method.
Open Gradle wrapper file

The build file may be missing a Gradle plugin.
Apply Gradle plugin
No actions that the studio offers naturally work. What to do?
 
I wrote that the error is not in grandle! And I already saw these links and in them useless information that did not help me.
You can take it and not be lazy and reproduce my steps, and then try to fix it and you will see that the problem is completely different. Either someone will already help me, or android studio is a garbage pit that you should not study
 
Back
Top Bottom