From c9538d672f71017e66b1f7283c76354dc50c9235 Mon Sep 17 00:00:00 2001 From: Ryan Collingham Date: Wed, 27 Dec 2023 15:40:34 +0000 Subject: [PATCH] format code with black --- test/errors/test_errors.py | 4 ++-- test/merkletreejs/test_merkle_proof_verify_compatibility.py | 5 ++--- 2 files changed, 4 insertions(+), 5 deletions(-) diff --git a/test/errors/test_errors.py b/test/errors/test_errors.py index 55790bc..a463f9f 100644 --- a/test/errors/test_errors.py +++ b/test/errors/test_errors.py @@ -28,10 +28,10 @@ def invalid_hash_function(data): def test_empty_tree_root(): - mtree = MerkleTree(['a', 'b', 'c', 'd']) + mtree = MerkleTree(["a", "b", "c", "d"]) mtree.leaves = [] with raises(ValueError) as error: mtree.root - assert str(error.value) == 'Cannot get root of an empty tree' + assert str(error.value) == "Cannot get root of an empty tree" diff --git a/test/merkletreejs/test_merkle_proof_verify_compatibility.py b/test/merkletreejs/test_merkle_proof_verify_compatibility.py index 4558a94..e937b23 100644 --- a/test/merkletreejs/test_merkle_proof_verify_compatibility.py +++ b/test/merkletreejs/test_merkle_proof_verify_compatibility.py @@ -28,11 +28,10 @@ def sha256(x, y): proof_py = [] for node in data_js["proof"]: - side = Side.RIGHT if node['position'] == 'right' else Side.LEFT - data = bytes.fromhex(node['data']) + side = Side.RIGHT if node["position"] == "right" else Side.LEFT + data = bytes.fromhex(node["data"]) proof_py.append(Node(data=data, side=side)) - leaves = ["a", "b", "c", "d", "e", "f", "g", "h"] mtree = MerkleTree(leaves, sha256) leaf = "a"