Skip to content

Commit

Permalink
🦍 feat: refactor test
Browse files Browse the repository at this point in the history
  • Loading branch information
mmsaki committed Feb 11, 2025
1 parent 6c985ac commit fba76c5
Showing 1 changed file with 6 additions and 3 deletions.
9 changes: 6 additions & 3 deletions tests/Vertex_test.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
import unittest

from defigraph.Vertex import Vertex
import pytest
from web3 import Web3
Expand Down Expand Up @@ -26,12 +27,14 @@ def setUp(self):
}

def test_address_should_be_valid_checksum(self):
name = self.pool["token0"]
decimals = int(self.pool["token0"]["decimals"])
address = self.pool["token0"]["id"] # should be checksum address
with pytest.raises(ValueError):
name = self.pool["token0"]
decimals = int(self.pool["token0"]["decimals"])
address = self.pool["token0"]["id"]
Vertex(name, decimals, address)

Vertex(name, decimals, Web3.to_checksum_address(address))

def tearDown(self):
return super().tearDown()

Expand Down

0 comments on commit fba76c5

Please sign in to comment.