Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion test/gui/features/add-account/account.feature
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ Feature: adding accounts
Then "Brian" account should be opened
And "Alice" account should be added

@skip

Scenario: Adding account with self signed certificate for the first time
Given the user has started the client
When the user adds the server "%local_server%"
Expand Down
12 changes: 5 additions & 7 deletions test/gui/pageObjects/AccountConnectionWizard.py
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ class AccountConnectionWizard:
selector="QApplication.Settings.centralwidget.dialogStack.SetupWizardWidget.contentWidget.AccountConfiguredWizardPage.advancedConfigGroupBox.advancedConfigGroupBoxContentWidget.localDirectoryGroupBox.chooseLocalDirectoryButton",
)
CHOOSE_FOLDER_BUTTON = SimpleNamespace(by=By.NAME, selector="Choose")
OAUTH_CREDENTIAL_PAGE = SimpleNamespace(by=None, selector=None)
LOGIN_DIALOG = SimpleNamespace(by=By.NAME, selector="Log in with your web browser")
COPY_URL_TO_CLIPBOARD_BUTTON = SimpleNamespace(
by=By.NAME,
selector="Copy URL",
Expand Down Expand Up @@ -192,12 +192,10 @@ def is_new_connection_window_visible():

@staticmethod
def is_credential_window_visible():
visible = False
try:
squish.waitForObject(AccountConnectionWizard.OAUTH_CREDENTIAL_PAGE)
visible = True
except:
pass
visible = app().find_element(
AccountConnectionWizard.LOGIN_DIALOG.by,
AccountConnectionWizard.LOGIN_DIALOG.selector
).is_displayed()
return visible

@staticmethod
Expand Down
16 changes: 7 additions & 9 deletions test/gui/steps/account_context.py
Original file line number Diff line number Diff line change
Expand Up @@ -179,9 +179,9 @@ def step(context):
AccountConnectionWizard.accept_certificate()


@When('the user adds the server "|any|"')
def step(context, server):
server_url = substitute_inline_codes(server)
@When('the user adds the server "{server_url}"')
def step(context, server_url):
server_url = substitute_inline_codes(server_url)
AccountConnectionWizard.add_server(server_url)


Expand All @@ -193,12 +193,10 @@ def step(context):

@Then('credentials wizard should be visible')
def step(context):
test.compare(
AccountConnectionWizard.is_credential_window_visible(),
True,
'Credentials wizard is visible',
)

with ensure(
'Credentials wizard is not be visible'
):
AccountConnectionWizard.is_credential_window_visible().should.be.true

@When('the user selects download everything option in advanced section')
def step(context):
Expand Down
Loading