Skip to content

Commit

Permalink
Merge pull request #2815 from IntersectMBO/imp_faucet
Browse files Browse the repository at this point in the history
fix(faucet): update docstrings and type hints
  • Loading branch information
mkoura authored Dec 2, 2024
2 parents 76dbef6 + 2219e68 commit e8e21c6
Showing 1 changed file with 4 additions and 5 deletions.
9 changes: 4 additions & 5 deletions cardano_node_tests/utils/faucet.py
Original file line number Diff line number Diff line change
Expand Up @@ -17,12 +17,12 @@ def fund_from_faucet(
cluster_obj: clusterlib.ClusterLib,
faucet_data: dict | None = None,
all_faucets: dict[str, dict] | None = None,
amount: None | int | list[int] = None,
amount: int | list[int] | None = None,
tx_name: str | None = None,
destination_dir: clusterlib.FileType = ".",
force: bool = False,
) -> clusterlib.TxRawOutput | None:
"""Send `amount` from faucet addr to all `dst_addrs`."""
"""Transfer `amount` from faucet addr to all `dst_addrs`."""
if amount is None:
amount = 1000_000_000

Expand All @@ -32,8 +32,7 @@ def fund_from_faucet(

# Get payment AddressRecord out of PoolUser
dst_addr_records: list[clusterlib.AddressRecord] = [
(r.payment if hasattr(r, "payment") else r)
for r in dst_addrs # type: ignore
(r.payment if hasattr(r, "payment") else r) for r in dst_addrs
]
if isinstance(amount, int):
amount = [amount] * len(dst_addr_records)
Expand Down Expand Up @@ -78,7 +77,7 @@ def return_funds_to_faucet(
tx_name: str | None = None,
destination_dir: cl_types.FileType = ".",
) -> None:
"""Send `amount` from all `src_addrs` to `faucet_addr`.
"""Transfer `amount` from all `src_addrs` to `faucet_addr`.
The amount of "-1" means all available funds.
"""
Expand Down

0 comments on commit e8e21c6

Please sign in to comment.