donnerpeter commented on a change in pull request #2283:
URL: https://github.com/apache/lucene-solr/pull/2283#discussion_r570083701



##########
File path: gradle/ant-compat/folder-layout.gradle
##########
@@ -25,11 +25,15 @@ allprojects {
       test.resources.srcDirs = ['src/test-files']
     }
 
-    task copyTestResources(type: Copy) {
+    task copyTestResources(type: Sync) {
       from('src/test') {
         exclude '**/*.java'
       }
       into sourceSets.test.java.outputDir
+      preserve {
+        include '**/*.class'
+        include 'META-INF/services/*'

Review comment:
       `Sync` deletes everything in the target which isn't in the source, and 
the target is a normal compiler output root, which contains class files etc. 
I've tried to enumerate things that shouldn't be deleted here, but I'm not 
terribly sure this list is exhaustive. I haven't seen issues with this settings 
so far, but I'm only working on Hunspell subset. What's worse, the issues I've 
seen before adding `preserve` appeared not immediately and somewhat randomly 
and weren't easy to decipher. So while the issue is there and should be 
addressed, I'm not sure this is the full fix.




----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscr...@lucene.apache.org
For additional commands, e-mail: issues-h...@lucene.apache.org

Reply via email to