Skip to content

Commit

Permalink
Remove date dependent screenshot path:
Browse files Browse the repository at this point in the history
* Do not implicitly overwrite settings.selenium.screenshots_path
* Date is already set in the filename
* Reduce datetime dependency
  • Loading branch information
dosas committed Oct 11, 2023
1 parent 051f6f1 commit d4754c1
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions airgun/session.py
Original file line number Diff line number Diff line change
Expand Up @@ -301,10 +301,8 @@ def take_screenshot(self):
session happens.
"""
now = datetime.now()
path = os.path.join(
settings.selenium.screenshots_path,
now.strftime('%Y-%m-%d'),
)
path = settings.selenium.screenshots_path

if not os.path.exists(path):
os.makedirs(path)
path = os.path.join(
Expand Down

0 comments on commit d4754c1

Please sign in to comment.