SatSale

Unnamed repository; edit this file 'description' to name the repository.
Log | Files | Refs | README | LICENSE

commit 921ae81f8380f9a09054c349e00f9835814a5f93
parent 5cde11fc31e0127747189f6e1fad11de4483322c
Author: Kristaps Kaupe <kristaps@blogiem.lv>
Date:   Fri, 14 Oct 2022 10:39:56 +0300

Fix flake8 errors

Diffstat:
Mpayments/price_feed.py | 2+-
Mtest/test_price_feed.py | 6+++---
2 files changed, 4 insertions(+), 4 deletions(-)

diff --git a/payments/price_feed.py b/payments/price_feed.py @@ -43,7 +43,7 @@ class PriceFeed(ABC): rate = self._get_rate(base_currency) if bitcoin_rate_multiplier != 1.00: logging.debug( - "Adjusting BTC/{} exchange rate from {} to {} " + + "Adjusting BTC/{} exchange rate from {} to {} " "because of rate multiplier {}.".format( base_currency, rate, rate * bitcoin_rate_multiplier, bitcoin_rate_multiplier)) diff --git a/test/test_price_feed.py b/test/test_price_feed.py @@ -44,8 +44,8 @@ def test_invalid_base_currency(price_feed: dict) -> None: ]) def test_btc_btc_price(price_feed: dict) -> None: provider = price_feed["class"](price_feed_url=None) - assert(provider.get_btc_value(1, "BTC") == 1) - assert(provider.get_btc_value(1000000, "sats") == 0.01) + assert (provider.get_btc_value(1, "BTC") == 1) + assert (provider.get_btc_value(1000000, "sats") == 0.01) @pytest.mark.parametrize( @@ -74,7 +74,7 @@ def test_fiat_btc_price(price_feed: dict) -> None: provider = price_feed["class"](price_feed_url=None) provider.set_price_data(read_price_feed_data(price_feed["data_file"])) for conv in price_feed["conversions"]: - assert( + assert ( provider.get_btc_value(conv["base_value"], conv["base_currency"]) == conv["btc_value"] )