Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
B
beem
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container Registry
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD 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
Show more breadcrumbs
hive
beem
Commits
d6bfc39a
Commit
d6bfc39a
authored
6 years ago
by
Holger Nahrstaedt
Browse files
Options
Downloads
Patches
Plain Diff
Fix vote unit-test by automatically using the newest account vote
parent
080076d3
No related branches found
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
tests/beem/test_vote.py
+6
-1
6 additions, 1 deletion
tests/beem/test_vote.py
with
6 additions
and
1 deletion
tests/beem/test_vote.py
+
6
−
1
View file @
d6bfc39a
...
@@ -8,6 +8,7 @@ from parameterized import parameterized
...
@@ -8,6 +8,7 @@ from parameterized import parameterized
from
pprint
import
pprint
from
pprint
import
pprint
from
beem
import
Steem
,
exceptions
from
beem
import
Steem
,
exceptions
from
beem.comment
import
Comment
from
beem.comment
import
Comment
from
beem.account
import
Account
from
beem.vote
import
Vote
,
ActiveVotes
,
AccountVotes
from
beem.vote
import
Vote
,
ActiveVotes
,
AccountVotes
from
beem.instance
import
set_shared_steem_instance
from
beem.instance
import
set_shared_steem_instance
from
beem.utils
import
construct_authorperm
,
resolve_authorperm
,
resolve_authorpermvoter
,
construct_authorpermvoter
from
beem.utils
import
construct_authorperm
,
resolve_authorperm
,
resolve_authorpermvoter
,
construct_authorpermvoter
...
@@ -37,7 +38,11 @@ class Testcases(unittest.TestCase):
...
@@ -37,7 +38,11 @@ class Testcases(unittest.TestCase):
set_shared_steem_instance
(
cls
.
bts
)
set_shared_steem_instance
(
cls
.
bts
)
cls
.
bts
.
set_default_account
(
"
test
"
)
cls
.
bts
.
set_default_account
(
"
test
"
)
cls
.
authorpermvoter
=
u
"
@gtg/steem-pressure-4-need-for-speed|gandalf
"
acc
=
Account
(
"
holger80
"
,
steem_instance
=
cls
.
bts
)
votes
=
acc
.
get_account_votes
()
last_vote
=
votes
[
0
]
cls
.
authorpermvoter
=
'
@
'
+
last_vote
[
'
authorperm
'
]
+
'
|
'
+
acc
[
"
name
"
]
[
author
,
permlink
,
voter
]
=
resolve_authorpermvoter
(
cls
.
authorpermvoter
)
[
author
,
permlink
,
voter
]
=
resolve_authorpermvoter
(
cls
.
authorpermvoter
)
cls
.
author
=
author
cls
.
author
=
author
cls
.
permlink
=
permlink
cls
.
permlink
=
permlink
...
...
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