Просмотр исходного кода

Also drop version.config to the build dir.

This allows tests not running against a jar to find the config
(and thus initialise IdentityManagers).

Change-Id: Ief27b9dfcb2451043f013a4aebba3ad51203ed4c
Reviewed-on: http://gerrit.dmdirc.com/4036
Reviewed-by: Greg Holmes <greg@dmdirc.com>
Automatic-Compile: DMDirc Build Manager
pull/1/head
Chris Smith 9 лет назад
Родитель
Сommit
1c243b9602
1 измененных файлов: 5 добавлений и 0 удалений
  1. 5
    0
      build.gradle

+ 5
- 0
build.gradle Просмотреть файл

@@ -101,9 +101,14 @@ task createVersionConfig << {
101 101
        def version = dp.moduleVersion.id
102 102
        targetFile << " " + version.group + " " + version.name + " " + version.version + "\n"
103 103
     }
104
+
105
+    // Copy to the build directory so it's accessible during tests
106
+    java.nio.file.Files.copy(targetFile.toPath(),
107
+       sourceSets.main.output.classesDir.toPath().resolve('com').resolve('dmdirc').resolve('version.config'));
104 108
 }
105 109
 
106 110
 jar.dependsOn createVersionConfig
111
+test.dependsOn createVersionConfig
107 112
 
108 113
 jar {
109 114
     from("$buildDir/version.config") {

Загрузка…
Отмена
Сохранить