Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
sakia
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Deploy
Releases
Model registry
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
This is an archived project. Repository and other project resources are read-only.
Show more breadcrumbs
clients
python
sakia
Commits
6b424e81
Commit
6b424e81
authored
9 years ago
by
inso
Browse files
Options
Downloads
Patches
Plain Diff
Fix tests
parent
09e03712
No related branches found
No related tags found
No related merge requests found
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
src/sakia/tests/functional/certification/test_certification.py
+5
-6
5 additions, 6 deletions
...akia/tests/functional/certification/test_certification.py
with
5 additions
and
6 deletions
src/sakia/tests/functional/certification/test_certification.py
+
5
−
6
View file @
6b424e81
import
sys
import
unittest
import
asyncio
import
quamash
import
time
import
logging
from
ucoinpy.documents.peer
import
BMAEndpoint
from
PyQt5.QtWidgets
import
QDialog
,
QDialogButtonBox
,
QMessageBox
,
QApplication
from
PyQt5.QtCore
import
QLocale
,
Qt
from
PyQt5.QtTest
import
QTest
from
ucoinpy.api.bma
import
API
from
ucoinpy.documents
import
Peer
from
sakia.tests.mocks.bma
import
init_new_community
from
sakia.core.registry.identities
import
IdentitiesRegistry
from
sakia.gui.certification
import
CertificationDialog
from
sakia.gui.certification
import
CertificationDialog
,
Ui_CertificationDialog
from
sakia.gui.password_asker
import
PasswordAskerDialog
from
sakia.core.app
import
Application
from
sakia.core
import
Account
,
Community
,
Wallet
...
...
@@ -57,7 +54,9 @@ class TestCertificationDialog(unittest.TestCase, QuamashTest):
time
.
sleep
(
2
)
certification_dialog
=
CertificationDialog
(
self
.
application
,
self
.
account
,
self
.
password_asker
)
self
.
password_asker
,
QDialog
(),
Ui_CertificationDialog
())
async
def
open_dialog
(
certification_dialog
):
srv
,
port
,
url
=
await
self
.
mock_new_community
.
create_server
()
...
...
@@ -74,7 +73,7 @@ class TestCertificationDialog(unittest.TestCase, QuamashTest):
QTest
.
mouseClick
(
certification_dialog
.
ui
.
radio_pubkey
,
Qt
.
LeftButton
)
QTest
.
keyClicks
(
certification_dialog
.
ui
.
edit_pubkey
,
"
FADxcH5LmXGmGFgdixSes6nWnC4Vb4pRUBYT81zQRhjn
"
)
QTest
.
mouseClick
(
certification_dialog
.
ui
.
button_box
.
button
(
QDialogButtonBox
.
Ok
),
Qt
.
LeftButton
)
await
asyncio
.
sleep
(
1
)
await
asyncio
.
sleep
(
2
)
topWidgets
=
QApplication
.
topLevelWidgets
()
for
w
in
topWidgets
:
if
type
(
w
)
is
QMessageBox
:
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment