Skip to content

Commit

Permalink
feat: add avm_version to algopy.Contract class options
Browse files Browse the repository at this point in the history
  • Loading branch information
daniel-makerx committed Feb 19, 2025
1 parent 0cc9807 commit fc53b0f
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions src/_algopy_testing/models/contract.py
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,7 @@ class _ContractMeta(type):
_name: str
_scratch_slots: typing.Any
_state_totals: StateTotals | None
_avm_version: int

def __init__(cls, *args: typing.Any, **kwargs: typing.Any) -> None:
super().__init__(*args, **kwargs)
Expand Down Expand Up @@ -93,10 +94,12 @@ def __init_subclass__(
algopy.urange | tuple[int | algopy.urange, ...] | list[int | algopy.urange] | None
) = None,
state_totals: StateTotals | None = None,
avm_version: int = 10,
):
cls._name = name or cls.__name__
cls._scratch_slots = scratch_slots
cls._state_totals = state_totals
cls._avm_version = avm_version

def approval_program(self) -> algopy.UInt64 | bool:
raise NotImplementedError("`approval_program` is not implemented.")
Expand Down

0 comments on commit fc53b0f

Please sign in to comment.