From b90ce08d0effade6a5bba62fbbaea2735c4e895f Mon Sep 17 00:00:00 2001 From: Mattias Reichel Date: Mon, 23 Dec 2024 08:55:03 +0100 Subject: [PATCH 1/2] fix: disable recording container Closes gh-117 --- .../plugin/geb/WebDriverContainerHolder.groovy | 12 +++++------- 1 file changed, 5 insertions(+), 7 deletions(-) diff --git a/src/testFixtures/groovy/grails/plugin/geb/WebDriverContainerHolder.groovy b/src/testFixtures/groovy/grails/plugin/geb/WebDriverContainerHolder.groovy index 6ee8a01..d8de20c 100644 --- a/src/testFixtures/groovy/grails/plugin/geb/WebDriverContainerHolder.groovy +++ b/src/testFixtures/groovy/grails/plugin/geb/WebDriverContainerHolder.groovy @@ -99,13 +99,11 @@ class WebDriverContainerHolder { currentConfiguration = specConfiguration currentContainer = new BrowserWebDriverContainer() - if (grailsGebSettings.recordingEnabled) { - currentContainer = currentContainer.withRecordingMode( - grailsGebSettings.recordingMode, - grailsGebSettings.recordingDirectory, - grailsGebSettings.recordingFormat - ) - } + currentContainer = currentContainer.withRecordingMode( + grailsGebSettings.recordingMode, + grailsGebSettings.recordingDirectory, + grailsGebSettings.recordingFormat + ) currentContainer.tap { withAccessToHost(true) start() From b8b8f6ef75883c6cebf72bb89ebb43335e2c3ccd Mon Sep 17 00:00:00 2001 From: Mattias Reichel Date: Mon, 23 Dec 2024 09:12:11 +0100 Subject: [PATCH 2/2] refactor: set recording mode directly on created container --- .../groovy/grails/plugin/geb/WebDriverContainerHolder.groovy | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/testFixtures/groovy/grails/plugin/geb/WebDriverContainerHolder.groovy b/src/testFixtures/groovy/grails/plugin/geb/WebDriverContainerHolder.groovy index d8de20c..de3d367 100644 --- a/src/testFixtures/groovy/grails/plugin/geb/WebDriverContainerHolder.groovy +++ b/src/testFixtures/groovy/grails/plugin/geb/WebDriverContainerHolder.groovy @@ -98,8 +98,7 @@ class WebDriverContainerHolder { } currentConfiguration = specConfiguration - currentContainer = new BrowserWebDriverContainer() - currentContainer = currentContainer.withRecordingMode( + currentContainer = new BrowserWebDriverContainer().withRecordingMode( grailsGebSettings.recordingMode, grailsGebSettings.recordingDirectory, grailsGebSettings.recordingFormat