make screenshots
This commit is contained in:
@@ -21,14 +21,14 @@ class TestExample(TestCase):
|
||||
def action():
|
||||
time.sleep(2)
|
||||
|
||||
self.check_by_screenshot_file(None, screenshot_path=f'test_search_block.png',
|
||||
self.check_by_screenshot_file(None, screenshot_path=f'{os.path.dirname(__file__)}/test_search_block.png',
|
||||
full_page=True, action=action)
|
||||
|
||||
def test_save_screenshot(self):
|
||||
def save_screenshot(self):
|
||||
self.driver.get("https://s57.ivazh.ru/styles/r14/#12.13/71.2832/72.13405")
|
||||
|
||||
def action():
|
||||
time.sleep(2)
|
||||
|
||||
self.save_screenshot('test_search_block.png', full_page=True, action=action)
|
||||
self.save_screenshot(f'{os.path.dirname(__file__)}/test_search_block.png', full_page=True, action=action)
|
||||
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
"""Screenshot TestCase."""
|
||||
|
||||
import logging
|
||||
import os.path
|
||||
import time
|
||||
from typing import Tuple
|
||||
from urllib.parse import urlparse
|
||||
|
||||
Reference in New Issue
Block a user