execCommand == null!

Hi,
I have written the following simple task in my android project.

task testing (type: Exec) {
        println workingDir
}

gradlew testing

when I run the above command in the command prompt(Windows), it gives an error:


> Task :testing FAILED

FAILURE: Build failed with an exception.

* What went wrong:
Execution failed for task ':testing'.
> execCommand == null!

OS: Windows
Gradle-Version: 6.7.1

I am unable to understand why I am getting this error?