Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
silkaj
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package Registry
Container Registry
Model registry
Operate
Terraform modules
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
clients
python
silkaj
Commits
b63c8c23
Commit
b63c8c23
authored
4 years ago
by
matograine
Browse files
Options
Downloads
Patches
Plain Diff
[test][mod] import silkaj.tx module in test_tx instead of single function
parent
abaa5741
No related branches found
No related tags found
1 merge request
!157
#362 tests amount 0
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
tests/test_tx.py
+3
-3
3 additions, 3 deletions
tests/test_tx.py
with
3 additions
and
3 deletions
tests/test_tx.py
+
3
−
3
View file @
b63c8c23
...
...
@@ -18,7 +18,7 @@ along with Silkaj. If not, see <https://www.gnu.org/licenses/>.
import
pytest
from
click.testing
import
CliRunner
from
silkaj
.tx
import
t
ransaction_amount
from
silkaj
import
t
x
from
silkaj.money
import
UDValue
from
silkaj.cli
import
cli
from
silkaj.constants
import
(
...
...
@@ -67,7 +67,7 @@ async def test_transaction_amount(monkeypatch):
)
for
trial
in
trials
:
assert
trial
[
3
]
==
await
transaction_amount
(
trial
[
0
],
trial
[
1
],
trial
[
2
])
assert
trial
[
3
]
==
await
tx
.
transaction_amount
(
trial
[
0
],
trial
[
1
],
trial
[
2
])
# transaction_amount errors()
...
...
@@ -115,7 +115,7 @@ async def test_transaction_amount_errors(
# check program exit on error
with
pytest
.
raises
(
SystemExit
)
as
pytest_exit
:
# read output to check error.
await
transaction_amount
(
amounts
,
UDs_amounts
,
outputAddresses
)
await
tx
.
transaction_amount
(
amounts
,
UDs_amounts
,
outputAddresses
)
assert
expected
==
capsys
.
readouterr
()
assert
pytest_exit
.
type
==
SystemExit
...
...
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