tvarchive / optimusTemplate

This is a cucumber jvm implementation template using the optimus mobile automation framework. If you like it, star it, help spread the word.
http://docs.testvagrant.com
66 stars 23 forks source link

Always failed to build after the first build (Unable to delete directory) #36

Closed chairulanwar closed 5 years ago

chairulanwar commented 5 years ago

I am new to Java and Optimus. After the first build of Optimus, I always got this error message when I run

gradle runDistribution -DtestFeed="helloOptimus" -Dtags=@helloOptimus

> Task :clean FAILED

FAILURE: Build failed with an exception.

* What went wrong:
Execution failed for task ':clean'.
> Unable to delete directory: C:\Users\Chairul\EDCAutomation\build

* Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output. Run with --scan to get full insights.

* Get more help at https://help.gradle.org

BUILD FAILED in 1s
1 actionable task: 1 executed

I can't manually delete the file/folder and already tried all the methods in here https://stackoverflow.com/questions/36492904/unable-to-delete-directory-in-android-studio.

I'm using Windows 10, Android Studio 3.2 and IntelliJ IDEA 2018.2.5

KrishnB commented 5 years ago

This is a permissions issue. You will need to run tests as an admin. This issue could be specific to windows