mirror of
https://github.com/freedombox/FreedomBox.git
synced 2026-05-20 10:34:30 +00:00
*: Minor flake8 fixes
Signed-off-by: Sunil Mohan Adapa <sunil@medhas.org>
This commit is contained in:
parent
e5cd5bd796
commit
9ef9a0fb1c
@ -130,13 +130,13 @@ def _visit_library(browser, name):
|
|||||||
raise ValueError('Library not found')
|
raise ValueError('Library not found')
|
||||||
|
|
||||||
link.first.click()
|
link.first.click()
|
||||||
functional.eventually(browser.find_by_css, [f'.book-list-cover-grid'])
|
functional.eventually(browser.find_by_css, ['.book-list-cover-grid'])
|
||||||
|
|
||||||
|
|
||||||
def _add_book(browser, library_name, book_name):
|
def _add_book(browser, library_name, book_name):
|
||||||
"""Add a book to the library through Calibre interface."""
|
"""Add a book to the library through Calibre interface."""
|
||||||
_visit_library(browser, library_name)
|
_visit_library(browser, library_name)
|
||||||
add_button = browser.find_by_css(f'a[data-button-icon="plus"]')
|
add_button = browser.find_by_css('a[data-button-icon="plus"]')
|
||||||
add_button.first.click()
|
add_button.first.click()
|
||||||
|
|
||||||
functional.eventually(browser.find_by_xpath,
|
functional.eventually(browser.find_by_xpath,
|
||||||
@ -163,7 +163,7 @@ def _delete_book(browser, library_name, book_name, ignore_missing=False):
|
|||||||
raise Exception('Book not found')
|
raise Exception('Book not found')
|
||||||
|
|
||||||
book.first.click()
|
book.first.click()
|
||||||
delete_button = browser.find_by_css(f'a[data-button-icon="trash"]')
|
delete_button = browser.find_by_css('a[data-button-icon="trash"]')
|
||||||
delete_button.first.click()
|
delete_button.first.click()
|
||||||
|
|
||||||
dialog = browser.find_by_id('modal-container').first
|
dialog = browser.find_by_id('modal-container').first
|
||||||
|
|||||||
@ -55,7 +55,7 @@ def disable_application(session_browser, app_name):
|
|||||||
@given(parsers.parse('the {app_name:w} application can be disabled'))
|
@given(parsers.parse('the {app_name:w} application can be disabled'))
|
||||||
def app_can_be_disabled(session_browser, app_name):
|
def app_can_be_disabled(session_browser, app_name):
|
||||||
if not functional.app_can_be_disabled(session_browser, app_name):
|
if not functional.app_can_be_disabled(session_browser, app_name):
|
||||||
pytest.skip(f'network time application can\'t be disabled')
|
pytest.skip('network time application can\'t be disabled')
|
||||||
|
|
||||||
|
|
||||||
@then(parsers.parse('the {service_name:w} service should be running'))
|
@then(parsers.parse('the {service_name:w} service should be running'))
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user