You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@groovy.apache.org by pa...@apache.org on 2019/09/26 08:45:31 UTC

[groovy] 05/05: avoid deprecated method call

This is an automated email from the ASF dual-hosted git repository.

paulk pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/groovy.git

commit ac64c64518a4d8fb2d017eb982564d7d3410a09b
Author: Paul King <pa...@asert.com.au>
AuthorDate: Thu Sep 26 18:45:11 2019 +1000

    avoid deprecated method call
---
 src/test/groovy/util/GroovyScriptEngineTest.groovy | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/src/test/groovy/util/GroovyScriptEngineTest.groovy b/src/test/groovy/util/GroovyScriptEngineTest.groovy
index 39dbc36..804a9dd 100644
--- a/src/test/groovy/util/GroovyScriptEngineTest.groovy
+++ b/src/test/groovy/util/GroovyScriptEngineTest.groovy
@@ -50,7 +50,7 @@ class GroovyScriptEngineTest extends GroovyTestCase {
         try {
             System.setProperty('groovy.ast', 'xml')
 
-            def clazz = new GroovyScriptEngine([temporaryFolder.root.toURL()] as URL[]).loadScriptByName('Script1.groovy')
+            def clazz = new GroovyScriptEngine([temporaryFolder.root.toURI().toURL()] as URL[]).loadScriptByName('Script1.groovy')
 
             assert new File(temporaryFolder.root, scriptFile.name + '.xml').exists()
             assert clazz != null
@@ -69,7 +69,7 @@ class GroovyScriptEngineTest extends GroovyTestCase {
 
         System.clearProperty('groovy.ast')
 
-        def clazz = new GroovyScriptEngine([temporaryFolder.root.toURL()] as URL[]).loadScriptByName('Script1.groovy')
+        def clazz = new GroovyScriptEngine([temporaryFolder.root.toURI().toURL()] as URL[]).loadScriptByName('Script1.groovy')
         assert clazz != null
 
         assert !new File(temporaryFolder.root, scriptFile.name + '.xml').exists()