1
0
Fork 0
mirror of https://github.com/borgbase/vorta synced 2024-12-22 15:57:34 +00:00
vorta/tests/test_source.py

14 lines
425 B
Python

import vorta.models
import vorta.views
def test_add_folder(qapp, qtbot, tmpdir, monkeypatch, choose_file_dialog):
monkeypatch.setattr(
vorta.views.source_tab, "choose_file_dialog", choose_file_dialog
)
main = qapp.main_window
main.tabWidget.setCurrentIndex(1)
tab = main.sourceTab
tab.sourceAddFolder.click()
qtbot.waitUntil(lambda: tab.sourceFilesWidget.rowCount() == 2, timeout=5000)