Fixed Gradle Wrapper, JavaDocs and JUnit test

Should not gotLock return the current lock status instead of trying to aquire a new lock?