diff --git a/silkaj/membership.py b/silkaj/membership.py index a9b63ffb7622ce8e3b3150ab8a225f5565d1f7ff..da81a4fae614f8bdf7d27cbf90186da01fdb45e7 100644 --- a/silkaj/membership.py +++ b/silkaj/membership.py @@ -30,7 +30,7 @@ from silkaj.tools import coroutine from silkaj.network_tools import ClientInstance from silkaj.blockchain_tools import BlockchainParams, HeadBlock from silkaj.license import license_approval -from silkaj.constants import SUCCESS_EXIT_STATUS +from silkaj.constants import SUCCESS_EXIT_STATUS, DATE @click.command( @@ -137,9 +137,8 @@ async def display_confirmation_table(identity_uid, pubkey, identity_timestamp): table.append(["Block Identity", str(identity_timestamp)[:45] + "…"]) block = await client(bma.blockchain.block, identity_timestamp.number) - table.append( - ["Identity published", pendulum.from_timestamp(block["time"]).format("LL")] - ) + date_idty_pub = pendulum.from_timestamp(block["time"], tz="local").format(DATE) + table.append(["Identity published", date_idty_pub]) params = await BlockchainParams().params membership_validity = ( diff --git a/tests/test_membership.py b/tests/test_membership.py index 7ae7f5fb64930299c0d25e54034c93e96d3b79c5..c763ffb78965ae622dc32d3db245788cb3e65fca 100644 --- a/tests/test_membership.py +++ b/tests/test_membership.py @@ -47,6 +47,7 @@ from silkaj.blockchain_tools import BlockchainParams, HeadBlock from silkaj.constants import ( SUCCESS_EXIT_STATUS, FAILURE_EXIT_STATUS, + DATE, ) from silkaj.tui import display_pubkey_and_checksum @@ -179,8 +180,9 @@ async def test_display_confirmation_table( table.append(["Block Identity", str(identity_timestamp)[:45] + "…"]) block = await client(bma.blockchain.block, identity_timestamp.number) + date_idty_pub = pendulum.from_timestamp(block["time"], tz="local").format(DATE) table.append( - ["Identity published", pendulum.from_timestamp(block["time"]).format("LL")], + ["Identity published", date_idty_pub], ) params = await BlockchainParams().params