summaryrefslogtreecommitdiffstats
path: root/extensions/pref/autoconfig/test/marionette
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2024-05-15 03:35:49 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2024-05-15 03:35:49 +0000
commitd8bbc7858622b6d9c278469aab701ca0b609cddf (patch)
treeeff41dc61d9f714852212739e6b3738b82a2af87 /extensions/pref/autoconfig/test/marionette
parentReleasing progress-linux version 125.0.3-1~progress7.99u1. (diff)
downloadfirefox-d8bbc7858622b6d9c278469aab701ca0b609cddf.tar.xz
firefox-d8bbc7858622b6d9c278469aab701ca0b609cddf.zip
Merging upstream version 126.0.
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'extensions/pref/autoconfig/test/marionette')
-rw-r--r--extensions/pref/autoconfig/test/marionette/test_autoconfig.py8
1 files changed, 7 insertions, 1 deletions
diff --git a/extensions/pref/autoconfig/test/marionette/test_autoconfig.py b/extensions/pref/autoconfig/test/marionette/test_autoconfig.py
index 0cdc0feede..778ef5699d 100644
--- a/extensions/pref/autoconfig/test/marionette/test_autoconfig.py
+++ b/extensions/pref/autoconfig/test/marionette/test_autoconfig.py
@@ -16,6 +16,8 @@ class TestAutoConfig(MarionetteTestCase):
os.remove(self.pref_file)
if hasattr(self, "autoconfig_file"):
os.remove(self.autoconfig_file)
+ if hasattr(self, "pref_file_dir_created"):
+ os.rmdir(self.pref_file_dir)
super(TestAutoConfig, self).tearDown()
@@ -48,7 +50,11 @@ class TestAutoConfig(MarionetteTestCase):
self.marionette.quit()
test_dir = os.path.dirname(__file__)
- self.pref_file = os.path.join(self.exe_dir, "defaults", "pref", "autoconfig.js")
+ self.pref_file_dir = os.path.join(self.exe_dir, "defaults", "pref")
+ if not os.path.exists(self.pref_file_dir):
+ os.makedirs(self.pref_file_dir, exist_ok=True)
+ self.pref_file_dir_created = True
+ self.pref_file = os.path.join(self.pref_file_dir, "autoconfig.js")
shutil.copyfile(os.path.join(test_dir, "autoconfig.js"), self.pref_file)
self.autoconfig_file = os.path.join(self.exe_dir, "autoconfig.cfg")
shutil.copyfile(os.path.join(test_dir, "autoconfig.cfg"), self.autoconfig_file)