-
Notifications
You must be signed in to change notification settings - Fork 6
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
d2cfafa
commit 999c6be
Showing
14 changed files
with
67 additions
and
24 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -4,16 +4,21 @@ Start by cloning the repository. | |
git clone [email protected]:trusttoken/bnb-tx-python.git | ||
``` | ||
|
||
Install dependencies | ||
### Install dependencies | ||
``` | ||
pipenv install | ||
pipenv install --dev | ||
``` | ||
|
||
Run flake8 | ||
### Run flake8 | ||
``` | ||
pipenv run flake8 | ||
``` | ||
|
||
### Run tests | ||
``` | ||
pipenv run ./runtests.py | ||
``` | ||
|
||
# Pull Requests | ||
Please try to adhere to the following guidelines. | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1,6 @@ | ||
from .bech32 import bech32_encode, address_bytes | ||
from .base import Amino, Repeated, String, Address, StringVarInt, StringToken, Token, VarInt, make_prefix | ||
from .crypto import uncompress_key, compress_key, verify_sig | ||
|
||
|
||
name = "binance_transaction" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,2 +1,2 @@ | ||
class UnsupportedBNBMessage(Exception): | ||
class UnsupportedBnbMessage(Exception): | ||
pass |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
#!/usr/bin/env python | ||
import argparse | ||
import os | ||
import sys | ||
|
||
import pytest | ||
|
||
|
||
def main(): | ||
os.environ['APP_ENV'] = 'testing' | ||
|
||
parser = argparse.ArgumentParser(add_help=False) | ||
parser.add_argument('--debug-level', default='info', choices=('debug', 'info', 'warning', 'error')) | ||
parser.add_argument('--coverage', action='store_true', default=False) | ||
parser.add_argument('--coverage-html', '--cov-html', action='store_true', default=False) | ||
|
||
args, pytest_args = parser.parse_known_args() | ||
|
||
use_coverage = args.coverage or args.coverage_html | ||
|
||
if use_coverage: | ||
pytest_args.extend(['--cov', 'bnbarb']) | ||
|
||
if args.coverage_html: | ||
pytest_args.extend(['--cov-report', 'html', '--cov-report', 'term']) | ||
|
||
print('--> Calling pytest with args: {}'.format(' '.join(pytest_args))) | ||
status = pytest.main(pytest_args) | ||
sys.exit(status) | ||
|
||
|
||
if __name__ == '__main__': | ||
main() |