diff --git a/pom.xml b/pom.xml index 8a959854..78970c08 100644 --- a/pom.xml +++ b/pom.xml @@ -177,9 +177,9 @@ 2.13.0 - org.codehaus.groovy - groovy-all - 3.0.8 + org.apache.groovy + groovy + 4.0.0-rc-1 pom @@ -472,4 +472,4 @@ - \ No newline at end of file + diff --git a/src/test/groovy/com/frameworkium/core/ui/video/VideoCaptureSpec.groovy b/src/test/groovy/com/frameworkium/core/ui/video/VideoCaptureSpec.groovy index 77705327..9ed7cd51 100644 --- a/src/test/groovy/com/frameworkium/core/ui/video/VideoCaptureSpec.groovy +++ b/src/test/groovy/com/frameworkium/core/ui/video/VideoCaptureSpec.groovy @@ -1,5 +1,6 @@ package com.frameworkium.core.ui.video +import org.apache.commons.io.FileUtils import spock.lang.Specification import java.nio.file.Files @@ -8,7 +9,7 @@ import java.util.concurrent.TimeoutException class VideoCaptureSpec extends Specification { def setup() { - VideoCapture.VIDEO_FOLDER.deleteDir() + FileUtils.deleteDirectory(VideoCapture.VIDEO_FOLDER.toFile()) } def array = [0, 1, 0, 1] as byte[] @@ -25,7 +26,8 @@ class VideoCaptureSpec extends Specification { when: sut.fetchAndSaveVideo("test1") then: - VideoCapture.VIDEO_FOLDER.resolve("test1-session1.ext").readBytes() == array + def filepath = VideoCapture.VIDEO_FOLDER.resolve("test1-session1.ext") + Files.readAllBytes(filepath) == array } def "doesn't save file on fetch timeout"() {