diff --git a/build.gradle b/build.gradle index 28bdd3ec..606318a3 100644 --- a/build.gradle +++ b/build.gradle @@ -50,6 +50,7 @@ dependencyManagement { } jar { + exclude "test/**" exclude "test/**/**" } diff --git a/src/main/groovy/grails/plugins/elasticsearch/ElasticsearchGrailsPlugin.groovy b/src/main/groovy/grails/plugins/elasticsearch/ElasticsearchGrailsPlugin.groovy index c12aa46d..72ac20af 100755 --- a/src/main/groovy/grails/plugins/elasticsearch/ElasticsearchGrailsPlugin.groovy +++ b/src/main/groovy/grails/plugins/elasticsearch/ElasticsearchGrailsPlugin.groovy @@ -37,16 +37,11 @@ class ElasticsearchGrailsPlugin extends Plugin { def loadAfter = ['services', 'mongodb'] - def pluginExcludes = [ - 'grails-app/controllers/test/**', - 'grails-app/services/test/**', - 'grails-app/views/elasticSearch/index.gsp', - 'grails-app/domain/test/**', - '**/test/**', - 'src/docs/**', - 'src/test/**', - 'src/integration-test/**' - ] + def pluginExcludes = [ + "grails-app/views/error.gsp", + "**/test/**", + "src/docs/**" + ] def license = 'APACHE' @@ -147,6 +142,6 @@ class ElasticsearchGrailsPlugin extends Plugin { void doWithDynamicMethods() { // Define the custom ElasticSearch mapping for searchable domain classes - DomainDynamicMethodsUtils.injectDynamicMethods(grailsApplication, applicationContext) + DomainDynamicMethodsUtils.injectDynamicMethods(grailsApplication, applicationContext) } }