From 51019826154371e47e9b5de990af133c582cc6a8 Mon Sep 17 00:00:00 2001 From: Nick Pilon Date: Thu, 13 Mar 2014 15:55:35 -0700 Subject: [PATCH] Pass in base and source separately when setting save directory. Structure is important for comparison script. --- lettuce_webdriver/screenshot.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/lettuce_webdriver/screenshot.py b/lettuce_webdriver/screenshot.py index 12d8dfb..d8385cf 100644 --- a/lettuce_webdriver/screenshot.py +++ b/lettuce_webdriver/screenshot.py @@ -6,11 +6,12 @@ ) import os.path -def set_save_directory(root): +def set_save_directory(base, source): """Sets the root save directory for saving screenshots. Screenshots will be saved in subdirectories under this directory by browser window size. """ + root = os.path.join(base, source) if not os.path.isdir(root): os.makedirs(root)