Mercurial > public > develkit
changeset 123:6f1918544f7f
Add test to cleanLocal to ensure local repo was removed
author | smith@nwoca.org |
---|---|
date | Wed, 06 Feb 2013 19:58:34 +0000 |
parents | 01dd7d9c930a |
children | 81a8ecfbc8fa |
files | init.gradle |
diffstat | 1 files changed, 6 insertions(+), 1 deletions(-) [+] |
line wrap: on
line diff
--- a/init.gradle Mon Jan 07 15:29:45 2013 -0500 +++ b/init.gradle Wed Feb 06 19:58:34 2013 +0000 @@ -38,7 +38,12 @@ if ( local ) { logger.info "removing local repo: $it" new File(System.properties['user.home'] + "/.ssdt/local-repo").deleteDir() - new File(gradle.ivyUserDir + "/local").deleteDir() + def localDir = new File(gradle.ivyUserDir + "/local") + localDir.deleteDir() + logger.info "verifying removal of local repo" + if (localDir.exists()) { + throw new org.gradle.api.GradleException("Unable to clean ${localDir}. Files may be locked by another process.") + } } }