algorand-python-testing 0.4.1b1__tar.gz → 0.5.0__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/.github/workflows/cd.yaml +2 -2
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/.gitignore +1 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/.vscode/settings.json +1 -2
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/CHANGELOG.md +57 -19
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/PKG-INFO +3 -3
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/README.md +1 -1
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/docs/testing-guide/opcodes.md +10 -8
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/pyproject.toml +3 -3
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/scripts/check_stubs_cov.py +85 -29
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/scripts/refresh_test_artifacts.py +2 -2
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/src/_algopy_testing/arc4.py +65 -42
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/src/_algopy_testing/compiled.py +2 -5
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/src/_algopy_testing/context_helpers/ledger_context.py +38 -6
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/src/_algopy_testing/decorators/arc4.py +27 -10
- algorand_python_testing-0.5.0/src/_algopy_testing/decorators/subroutine.py +25 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/src/_algopy_testing/models/account.py +6 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/src/_algopy_testing/models/contract.py +5 -2
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/src/_algopy_testing/models/txn_fields.py +2 -1
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/src/_algopy_testing/op/__init__.py +12 -0
- algorand_python_testing-0.5.0/src/_algopy_testing/op/block.py +51 -0
- algorand_python_testing-0.5.0/src/_algopy_testing/op/constants.py +30 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/src/_algopy_testing/op/crypto.py +30 -6
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/src/_algopy_testing/op/global_values.py +5 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/src/_algopy_testing/op/misc.py +200 -34
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/src/_algopy_testing/primitives/__init__.py +2 -1
- algorand_python_testing-0.5.0/src/_algopy_testing/primitives/array.py +144 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/src/_algopy_testing/primitives/bytes.py +4 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/src/_algopy_testing/protocols.py +12 -0
- algorand_python_testing-0.5.0/src/_algopy_testing/serialize.py +158 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/src/_algopy_testing/state/utils.py +7 -1
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/src/_algopy_testing/utils.py +5 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/src/algopy/__init__.py +7 -5
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/templates/.macros.j2 +1 -1
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/tests/arc4/conftest.py +3 -3
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/tests/arc4/test_arc4_method_signature.py +33 -27
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/tests/arc4/test_struct.py +10 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/tests/artifacts/Arc4ABIMethod/data/SignaturesContract.approval.teal +158 -166
- algorand_python_testing-0.5.0/tests/artifacts/Arc4ABIMethod/data/SignaturesContract.arc32.json +253 -0
- algorand_python_testing-0.5.0/tests/artifacts/Arc4ABIMethod/data/SignaturesContract.clear.teal +7 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/tests/artifacts/Arc4InnerTxns/data/Arc4InnerTxnsContract.approval.teal +23 -16
- algorand_python_testing-0.5.0/tests/artifacts/Arc4InnerTxns/data/Arc4InnerTxnsContract.arc32.json +55 -0
- algorand_python_testing-0.5.0/tests/artifacts/Arc4InnerTxns/data/Arc4InnerTxnsContract.clear.teal +7 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/tests/artifacts/Arc4PrimitiveOps/data/Arc4PrimitiveOpsContract.approval.teal +692 -860
- algorand_python_testing-0.5.0/tests/artifacts/Arc4PrimitiveOps/data/Arc4PrimitiveOpsContract.arc32.json +1029 -0
- algorand_python_testing-0.5.0/tests/artifacts/Arc4PrimitiveOps/data/Arc4PrimitiveOpsContract.clear.teal +7 -0
- algorand_python_testing-0.5.0/tests/artifacts/Arrays/data/Contract.approval.teal +1675 -0
- algorand_python_testing-0.5.0/tests/artifacts/Arrays/data/Contract.arc32.json +172 -0
- algorand_python_testing-0.5.0/tests/artifacts/Arrays/data/Contract.clear.teal +7 -0
- algorand_python_testing-0.5.0/tests/artifacts/Arrays/data/ImmutableArrayContract.approval.teal +3421 -0
- algorand_python_testing-0.5.0/tests/artifacts/Arrays/data/ImmutableArrayContract.arc32.json +450 -0
- algorand_python_testing-0.5.0/tests/artifacts/Arrays/data/ImmutableArrayContract.clear.teal +7 -0
- algorand_python_testing-0.5.0/tests/artifacts/Arrays/data/StaticSizeContract.approval.teal +902 -0
- algorand_python_testing-0.5.0/tests/artifacts/Arrays/data/StaticSizeContract.arc32.json +162 -0
- algorand_python_testing-0.5.0/tests/artifacts/Arrays/data/StaticSizeContract.clear.teal +7 -0
- algorand_python_testing-0.5.0/tests/artifacts/Arrays/immutable.py +428 -0
- algorand_python_testing-0.5.0/tests/artifacts/Arrays/static_size.py +135 -0
- algorand_python_testing-0.5.0/tests/artifacts/Arrays/uint64.py +255 -0
- algorand_python_testing-0.5.0/tests/artifacts/BoxContract/data/BoxContract.approval.teal +128 -0
- algorand_python_testing-0.5.0/tests/artifacts/BoxContract/data/BoxContract.arc32.json +63 -0
- algorand_python_testing-0.5.0/tests/artifacts/BoxContract/data/BoxContract.clear.teal +7 -0
- algorand_python_testing-0.5.0/tests/artifacts/Contains/data/MyContract.approval.teal +192 -0
- algorand_python_testing-0.5.0/tests/artifacts/Contains/data/MyContract.clear.teal +9 -0
- algorand_python_testing-0.5.0/tests/artifacts/CreatedAppAsset/data/AppCall.approval.teal +58 -0
- algorand_python_testing-0.5.0/tests/artifacts/CreatedAppAsset/data/AppCall.arc32.json +50 -0
- algorand_python_testing-0.5.0/tests/artifacts/CreatedAppAsset/data/AppCall.clear.teal +7 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/tests/artifacts/CreatedAppAsset/data/AppExpectingEffects.approval.teal +56 -49
- algorand_python_testing-0.5.0/tests/artifacts/CreatedAppAsset/data/AppExpectingEffects.arc32.json +77 -0
- algorand_python_testing-0.5.0/tests/artifacts/CreatedAppAsset/data/AppExpectingEffects.clear.teal +7 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/tests/artifacts/CryptoOps/data/CryptoOpsContract.approval.teal +304 -329
- algorand_python_testing-0.5.0/tests/artifacts/CryptoOps/data/CryptoOpsContract.arc32.json +368 -0
- algorand_python_testing-0.5.0/tests/artifacts/CryptoOps/data/CryptoOpsContract.clear.teal +7 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/tests/artifacts/GlobalStateValidator/data/GlobalStateValidator.approval.teal +26 -18
- algorand_python_testing-0.5.0/tests/artifacts/GlobalStateValidator/data/GlobalStateValidator.arc32.json +59 -0
- algorand_python_testing-0.5.0/tests/artifacts/GlobalStateValidator/data/GlobalStateValidator.clear.teal +7 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/tests/artifacts/MiscellaneousOps/data/MiscellaneousOpsContract.approval.teal +421 -464
- algorand_python_testing-0.5.0/tests/artifacts/MiscellaneousOps/data/MiscellaneousOpsContract.arc32.json +858 -0
- algorand_python_testing-0.5.0/tests/artifacts/MiscellaneousOps/data/MiscellaneousOpsContract.clear.teal +7 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/tests/artifacts/PrimitiveOps/data/PrimitiveOpsContract.approval.teal +750 -801
- algorand_python_testing-0.5.0/tests/artifacts/PrimitiveOps/data/PrimitiveOpsContract.arc32.json +1393 -0
- algorand_python_testing-0.5.0/tests/artifacts/PrimitiveOps/data/PrimitiveOpsContract.clear.teal +7 -0
- algorand_python_testing-0.5.0/tests/artifacts/StateMutations/data/StateMutations.approval.teal +766 -0
- algorand_python_testing-0.5.0/tests/artifacts/StateMutations/data/StateMutations.arc32.json +95 -0
- algorand_python_testing-0.5.0/tests/artifacts/StateMutations/data/StateMutations.clear.teal +7 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/tests/artifacts/StateOps/contract.py +25 -1
- algorand_python_testing-0.5.0/tests/artifacts/StateOps/data/GlobalStateContract.approval.teal +935 -0
- algorand_python_testing-0.5.0/tests/artifacts/StateOps/data/GlobalStateContract.arc32.json +528 -0
- algorand_python_testing-0.5.0/tests/artifacts/StateOps/data/GlobalStateContract.clear.teal +7 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/tests/artifacts/StateOps/data/ITxnOpsContract.approval.teal +53 -49
- algorand_python_testing-0.5.0/tests/artifacts/StateOps/data/ITxnOpsContract.arc32.json +50 -0
- algorand_python_testing-0.5.0/tests/artifacts/StateOps/data/ITxnOpsContract.clear.teal +7 -0
- algorand_python_testing-0.5.0/tests/artifacts/StateOps/data/LocalStateContract.approval.teal +695 -0
- algorand_python_testing-0.5.0/tests/artifacts/StateOps/data/LocalStateContract.arc32.json +359 -0
- algorand_python_testing-0.5.0/tests/artifacts/StateOps/data/LocalStateContract.clear.teal +7 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/tests/artifacts/StateOps/data/StateAcctParamsGetContract.approval.teal +377 -214
- algorand_python_testing-0.5.0/tests/artifacts/StateOps/data/StateAcctParamsGetContract.arc32.json +307 -0
- algorand_python_testing-0.5.0/tests/artifacts/StateOps/data/StateAcctParamsGetContract.clear.teal +7 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/tests/artifacts/StateOps/data/StateAppGlobalContract.approval.teal +135 -134
- algorand_python_testing-0.5.0/tests/artifacts/StateOps/data/StateAppGlobalContract.arc32.json +188 -0
- algorand_python_testing-0.5.0/tests/artifacts/StateOps/data/StateAppGlobalContract.clear.teal +7 -0
- algorand_python_testing-0.5.0/tests/artifacts/StateOps/data/StateAppGlobalExContract.approval.teal +75 -0
- algorand_python_testing-0.5.0/tests/artifacts/StateOps/data/StateAppGlobalExContract.arc32.json +60 -0
- algorand_python_testing-0.5.0/tests/artifacts/StateOps/data/StateAppGlobalExContract.clear.teal +7 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/tests/artifacts/StateOps/data/StateAppLocalContract.approval.teal +162 -175
- algorand_python_testing-0.5.0/tests/artifacts/StateOps/data/StateAppLocalContract.arc32.json +251 -0
- algorand_python_testing-0.5.0/tests/artifacts/StateOps/data/StateAppLocalContract.clear.teal +7 -0
- algorand_python_testing-0.5.0/tests/artifacts/StateOps/data/StateAppLocalExContract.approval.teal +67 -0
- algorand_python_testing-0.5.0/tests/artifacts/StateOps/data/StateAppLocalExContract.arc32.json +63 -0
- algorand_python_testing-0.5.0/tests/artifacts/StateOps/data/StateAppLocalExContract.clear.teal +7 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/tests/artifacts/StateOps/data/StateAppParamsContract.approval.teal +220 -224
- algorand_python_testing-0.5.0/tests/artifacts/StateOps/data/StateAppParamsContract.arc32.json +199 -0
- algorand_python_testing-0.5.0/tests/artifacts/StateOps/data/StateAppParamsContract.clear.teal +7 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/tests/artifacts/StateOps/data/StateAssetHoldingContract.approval.teal +49 -42
- algorand_python_testing-0.5.0/tests/artifacts/StateOps/data/StateAssetHoldingContract.arc32.json +81 -0
- algorand_python_testing-0.5.0/tests/artifacts/StateOps/data/StateAssetHoldingContract.clear.teal +7 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/tests/artifacts/StateOps/data/StateAssetParamsContract.approval.teal +288 -292
- algorand_python_testing-0.5.0/tests/artifacts/StateOps/data/StateAssetParamsContract.arc32.json +253 -0
- algorand_python_testing-0.5.0/tests/artifacts/StateOps/data/StateAssetParamsContract.clear.teal +7 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/tests/common.py +46 -53
- algorand_python_testing-0.5.0/tests/conftest.py +24 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/tests/primitives/conftest.py +3 -3
- algorand_python_testing-0.5.0/tests/state/conftest.py +26 -0
- algorand_python_testing-0.5.0/tests/test_array.py +228 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/tests/test_miscellaneous_op.py +3 -3
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/tests/test_op.py +160 -102
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/tests/utilities/conftest.py +3 -3
- algorand_python_testing-0.5.0/tests/value_generators/__init__.py +0 -0
- algorand_python_testing-0.4.1b1/src/_algopy_testing/decorators/subroutine.py +0 -9
- algorand_python_testing-0.4.1b1/src/_algopy_testing/op/block.py +0 -28
- algorand_python_testing-0.4.1b1/src/_algopy_testing/op/constants.py +0 -7
- algorand_python_testing-0.4.1b1/tests/artifacts/Arc4ABIMethod/data/SignaturesContract.arc32.json +0 -253
- algorand_python_testing-0.4.1b1/tests/artifacts/Arc4ABIMethod/data/SignaturesContract.clear.teal +0 -7
- algorand_python_testing-0.4.1b1/tests/artifacts/Arc4InnerTxns/data/Arc4InnerTxnsContract.arc32.json +0 -55
- algorand_python_testing-0.4.1b1/tests/artifacts/Arc4InnerTxns/data/Arc4InnerTxnsContract.clear.teal +0 -7
- algorand_python_testing-0.4.1b1/tests/artifacts/Arc4PrimitiveOps/data/Arc4PrimitiveOpsContract.arc32.json +0 -1029
- algorand_python_testing-0.4.1b1/tests/artifacts/Arc4PrimitiveOps/data/Arc4PrimitiveOpsContract.clear.teal +0 -7
- algorand_python_testing-0.4.1b1/tests/artifacts/BoxContract/data/BoxContract.approval.teal +0 -151
- algorand_python_testing-0.4.1b1/tests/artifacts/BoxContract/data/BoxContract.arc32.json +0 -63
- algorand_python_testing-0.4.1b1/tests/artifacts/BoxContract/data/BoxContract.clear.teal +0 -7
- algorand_python_testing-0.4.1b1/tests/artifacts/Contains/data/MyContract.approval.teal +0 -1479
- algorand_python_testing-0.4.1b1/tests/artifacts/Contains/data/MyContract.clear.teal +0 -7
- algorand_python_testing-0.4.1b1/tests/artifacts/CreatedAppAsset/data/AppExpectingEffects.arc32.json +0 -77
- algorand_python_testing-0.4.1b1/tests/artifacts/CreatedAppAsset/data/AppExpectingEffects.clear.teal +0 -7
- algorand_python_testing-0.4.1b1/tests/artifacts/CryptoOps/data/CryptoOpsContract.arc32.json +0 -368
- algorand_python_testing-0.4.1b1/tests/artifacts/CryptoOps/data/CryptoOpsContract.clear.teal +0 -7
- algorand_python_testing-0.4.1b1/tests/artifacts/GlobalStateValidator/data/GlobalStateValidator.arc32.json +0 -59
- algorand_python_testing-0.4.1b1/tests/artifacts/GlobalStateValidator/data/GlobalStateValidator.clear.teal +0 -7
- algorand_python_testing-0.4.1b1/tests/artifacts/MiscellaneousOps/data/MiscellaneousOpsContract.arc32.json +0 -858
- algorand_python_testing-0.4.1b1/tests/artifacts/MiscellaneousOps/data/MiscellaneousOpsContract.clear.teal +0 -7
- algorand_python_testing-0.4.1b1/tests/artifacts/PrimitiveOps/data/PrimitiveOpsContract.arc32.json +0 -1393
- algorand_python_testing-0.4.1b1/tests/artifacts/PrimitiveOps/data/PrimitiveOpsContract.clear.teal +0 -7
- algorand_python_testing-0.4.1b1/tests/artifacts/StateOps/data/GlobalStateContract.approval.teal +0 -1109
- algorand_python_testing-0.4.1b1/tests/artifacts/StateOps/data/GlobalStateContract.arc32.json +0 -528
- algorand_python_testing-0.4.1b1/tests/artifacts/StateOps/data/GlobalStateContract.clear.teal +0 -7
- algorand_python_testing-0.4.1b1/tests/artifacts/StateOps/data/ITxnOpsContract.arc32.json +0 -50
- algorand_python_testing-0.4.1b1/tests/artifacts/StateOps/data/ITxnOpsContract.clear.teal +0 -7
- algorand_python_testing-0.4.1b1/tests/artifacts/StateOps/data/LocalStateContract.approval.teal +0 -817
- algorand_python_testing-0.4.1b1/tests/artifacts/StateOps/data/LocalStateContract.arc32.json +0 -359
- algorand_python_testing-0.4.1b1/tests/artifacts/StateOps/data/LocalStateContract.clear.teal +0 -7
- algorand_python_testing-0.4.1b1/tests/artifacts/StateOps/data/StateAcctParamsGetContract.arc32.json +0 -253
- algorand_python_testing-0.4.1b1/tests/artifacts/StateOps/data/StateAcctParamsGetContract.clear.teal +0 -7
- algorand_python_testing-0.4.1b1/tests/artifacts/StateOps/data/StateAppGlobalContract.arc32.json +0 -188
- algorand_python_testing-0.4.1b1/tests/artifacts/StateOps/data/StateAppGlobalContract.clear.teal +0 -7
- algorand_python_testing-0.4.1b1/tests/artifacts/StateOps/data/StateAppGlobalExContract.approval.teal +0 -77
- algorand_python_testing-0.4.1b1/tests/artifacts/StateOps/data/StateAppGlobalExContract.arc32.json +0 -60
- algorand_python_testing-0.4.1b1/tests/artifacts/StateOps/data/StateAppGlobalExContract.clear.teal +0 -7
- algorand_python_testing-0.4.1b1/tests/artifacts/StateOps/data/StateAppLocalContract.arc32.json +0 -251
- algorand_python_testing-0.4.1b1/tests/artifacts/StateOps/data/StateAppLocalContract.clear.teal +0 -7
- algorand_python_testing-0.4.1b1/tests/artifacts/StateOps/data/StateAppLocalExContract.approval.teal +0 -77
- algorand_python_testing-0.4.1b1/tests/artifacts/StateOps/data/StateAppLocalExContract.arc32.json +0 -63
- algorand_python_testing-0.4.1b1/tests/artifacts/StateOps/data/StateAppLocalExContract.clear.teal +0 -7
- algorand_python_testing-0.4.1b1/tests/artifacts/StateOps/data/StateAppParamsContract.arc32.json +0 -199
- algorand_python_testing-0.4.1b1/tests/artifacts/StateOps/data/StateAppParamsContract.clear.teal +0 -7
- algorand_python_testing-0.4.1b1/tests/artifacts/StateOps/data/StateAssetHoldingContract.arc32.json +0 -81
- algorand_python_testing-0.4.1b1/tests/artifacts/StateOps/data/StateAssetHoldingContract.clear.teal +0 -7
- algorand_python_testing-0.4.1b1/tests/artifacts/StateOps/data/StateAssetParamsContract.arc32.json +0 -253
- algorand_python_testing-0.4.1b1/tests/artifacts/StateOps/data/StateAssetParamsContract.clear.teal +0 -7
- algorand_python_testing-0.4.1b1/tests/conftest.py +0 -54
- algorand_python_testing-0.4.1b1/tests/state/conftest.py +0 -23
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/.coveragerc +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/.editorconfig +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/.github/ISSUE_TEMPLATE/bug_report.md +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/.github/ISSUE_TEMPLATE/feature_request.md +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/.github/dependabot.yml +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/.github/pull_request_template.md +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/.github/workflows/ci.yaml +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/.github/workflows/gh-pages.yaml +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/.pre-commit-config.yaml +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/.vscode/extensions.json +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/.vscode/launch.json +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/CONTRIBUTING.md +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/LICENSE +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/docs/Makefile +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/docs/__init__.py +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/docs/_static/custom.css +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/docs/algopy.md +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/docs/api.md +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/docs/conf.py +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/docs/coverage.md +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/docs/examples.md +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/docs/faq.md +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/docs/index.md +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/docs/make.bat +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/docs/testing-guide/arc4-types.md +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/docs/testing-guide/avm-types.md +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/docs/testing-guide/concepts.md +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/docs/testing-guide/contract-testing.md +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/docs/testing-guide/index.md +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/docs/testing-guide/signature-testing.md +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/docs/testing-guide/state-management.md +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/docs/testing-guide/subroutines.md +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/docs/testing-guide/transactions.md +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/examples/README.md +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/examples/__init__.py +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/examples/auction/__init__.py +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/examples/auction/contract.py +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/examples/auction/test_contract.py +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/examples/htlc_logicsig/__init__.py +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/examples/htlc_logicsig/signature.py +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/examples/htlc_logicsig/test_signature.py +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/examples/marketplace/__init__.py +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/examples/marketplace/contract.py +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/examples/marketplace/test_contract.py +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/examples/proof_of_attendance/__init__.py +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/examples/proof_of_attendance/contract.py +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/examples/proof_of_attendance/test_contract.py +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/examples/scratch_storage/__init__.py +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/examples/scratch_storage/contract.py +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/examples/scratch_storage/test_contract.py +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/examples/simple_voting/__init__.py +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/examples/simple_voting/contract.py +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/examples/simple_voting/test_contract.py +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/examples/zk_whitelist/__init__.py +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/examples/zk_whitelist/contract.py +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/examples/zk_whitelist/test_contract.py +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/scripts/__init__.py +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/scripts/validate_examples.py +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/src/_algopy_testing/__init__.py +6 -6
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/src/_algopy_testing/constants.py +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/src/_algopy_testing/context.py +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/src/_algopy_testing/context_helpers/__init__.py +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/src/_algopy_testing/context_helpers/context_storage.py +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/src/_algopy_testing/context_helpers/txn_context.py +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/src/_algopy_testing/decorators/__init__.py +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/src/_algopy_testing/enums.py +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/src/_algopy_testing/gtxn.py +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/src/_algopy_testing/itxn.py +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/src/_algopy_testing/itxn_loader.py +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/src/_algopy_testing/models/__init__.py +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/src/_algopy_testing/models/application.py +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/src/_algopy_testing/models/asset.py +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/src/_algopy_testing/models/logicsig.py +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/src/_algopy_testing/models/template_variable.py +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/src/_algopy_testing/models/unsigned_builtins.py +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/src/_algopy_testing/mutable.py +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/src/_algopy_testing/op/itxn.py +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/src/_algopy_testing/op/pure.py +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/src/_algopy_testing/op/txn.py +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/src/_algopy_testing/primitives/biguint.py +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/src/_algopy_testing/primitives/string.py +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/src/_algopy_testing/primitives/uint64.py +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/src/_algopy_testing/py.typed +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/src/_algopy_testing/state/__init__.py +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/src/_algopy_testing/state/box.py +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/src/_algopy_testing/state/global_state.py +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/src/_algopy_testing/state/local_state.py +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/src/_algopy_testing/utilities/__init__.py +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/src/_algopy_testing/utilities/budget.py +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/src/_algopy_testing/utilities/log.py +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/src/_algopy_testing/value_generators/__init__.py +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/src/_algopy_testing/value_generators/arc4.py +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/src/_algopy_testing/value_generators/avm.py +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/src/_algopy_testing/value_generators/txn.py +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/src/algopy/arc4.py +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/src/algopy/gtxn.py +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/src/algopy/itxn.py +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/src/algopy/op.py +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/src/algopy/py.typed +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/src/algopy_testing/__init__.py +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/src/algopy_testing/py.typed +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/templates/.release_notes.md.j2 +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/templates/CHANGELOG.md.j2 +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/tests/__init__.py +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/tests/arc4/__init__.py +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/tests/arc4/test_abi_call.py +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/tests/arc4/test_address.py +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/tests/arc4/test_bool.py +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/tests/arc4/test_dynamic_array.py +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/tests/arc4/test_dynamic_bytes.py +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/tests/arc4/test_emit.py +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/tests/arc4/test_static_array.py +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/tests/arc4/test_string.py +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/tests/arc4/test_tuple.py +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/tests/arc4/test_ufixednxm.py +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/tests/arc4/test_uintn.py +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/tests/artifacts/Arc4ABIMethod/__init__.py +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/tests/artifacts/Arc4ABIMethod/contract.py +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/tests/artifacts/Arc4InnerTxns/__init__.py +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/tests/artifacts/Arc4InnerTxns/contract.py +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/tests/artifacts/Arc4PrimitiveOps/__init__.py +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/tests/artifacts/Arc4PrimitiveOps/contract.py +0 -0
- {algorand_python_testing-0.4.1b1/tests/artifacts/BoxContract → algorand_python_testing-0.5.0/tests/artifacts/Arrays}/__init__.py +0 -0
- {algorand_python_testing-0.4.1b1/tests/artifacts/Contains → algorand_python_testing-0.5.0/tests/artifacts/BoxContract}/__init__.py +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/tests/artifacts/BoxContract/contract.py +0 -0
- {algorand_python_testing-0.4.1b1/tests/artifacts/CreatedAppAsset → algorand_python_testing-0.5.0/tests/artifacts/Contains}/__init__.py +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/tests/artifacts/Contains/contract.py +0 -0
- {algorand_python_testing-0.4.1b1/tests/artifacts/CryptoOps → algorand_python_testing-0.5.0/tests/artifacts/CreatedAppAsset}/__init__.py +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/tests/artifacts/CreatedAppAsset/contract.py +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/tests/artifacts/CreatedAppAsset/other.py +0 -0
- {algorand_python_testing-0.4.1b1/tests/artifacts/GlobalStateValidator → algorand_python_testing-0.5.0/tests/artifacts/CryptoOps}/__init__.py +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/tests/artifacts/CryptoOps/contract.py +0 -0
- {algorand_python_testing-0.4.1b1/tests/artifacts/MiscellaneousOps → algorand_python_testing-0.5.0/tests/artifacts/GlobalStateValidator}/__init__.py +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/tests/artifacts/GlobalStateValidator/contract.py +0 -0
- {algorand_python_testing-0.4.1b1/tests/artifacts/PrimitiveOps → algorand_python_testing-0.5.0/tests/artifacts/MiscellaneousOps}/__init__.py +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/tests/artifacts/MiscellaneousOps/contract.py +0 -0
- {algorand_python_testing-0.4.1b1/tests/artifacts/StateMutations → algorand_python_testing-0.5.0/tests/artifacts/PrimitiveOps}/__init__.py +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/tests/artifacts/PrimitiveOps/contract.py +0 -0
- {algorand_python_testing-0.4.1b1/tests/artifacts/StateOps → algorand_python_testing-0.5.0/tests/artifacts/StateMutations}/__init__.py +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/tests/artifacts/StateMutations/data/Contract.approval.teal +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/tests/artifacts/StateMutations/data/Contract.arc32.json +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/tests/artifacts/StateMutations/data/Contract.clear.teal +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/tests/artifacts/StateMutations/statemutations.py +0 -0
- {algorand_python_testing-0.4.1b1/tests/artifacts → algorand_python_testing-0.5.0/tests/artifacts/StateOps}/__init__.py +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/tests/artifacts/StateOps/data/StateAcctParamsGet.approval.teal +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/tests/artifacts/StateOps/data/StateAcctParamsGet.arc32.json +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/tests/artifacts/StateOps/data/StateAcctParamsGet.clear.teal +0 -0
- {algorand_python_testing-0.4.1b1/tests/contexts → algorand_python_testing-0.5.0/tests/artifacts}/__init__.py +0 -0
- {algorand_python_testing-0.4.1b1/tests/models → algorand_python_testing-0.5.0/tests/contexts}/__init__.py +0 -0
- {algorand_python_testing-0.4.1b1/tests/primitives → algorand_python_testing-0.5.0/tests/models}/__init__.py +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/tests/models/test_asset.py +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/tests/models/test_box.py +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/tests/models/test_box_map.py +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/tests/models/test_box_ref.py +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/tests/models/test_contract.py +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/tests/models/test_uenumerate.py +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/tests/models/test_urange.py +0 -0
- {algorand_python_testing-0.4.1b1/tests/state → algorand_python_testing-0.5.0/tests/primitives}/__init__.py +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/tests/primitives/test_biguint.py +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/tests/primitives/test_bytes.py +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/tests/primitives/test_string.py +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/tests/primitives/test_uint64.py +0 -0
- {algorand_python_testing-0.4.1b1/tests/utilities → algorand_python_testing-0.5.0/tests/state}/__init__.py +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/tests/state/test_global_state.py +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/tests/state/test_local_state.py +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/tests/state/test_mutations.py +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/tests/test_context.py +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/tests/util.py +0 -0
- {algorand_python_testing-0.4.1b1/tests/value_generators → algorand_python_testing-0.5.0/tests/utilities}/__init__.py +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/tests/utilities/test_log.py +0 -0
- {algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/tests/value_generators/test_avm.py +0 -0
|
@@ -45,7 +45,7 @@ jobs:
|
|
|
45
45
|
- uses: actions/checkout@v4
|
|
46
46
|
with:
|
|
47
47
|
fetch-depth: 0
|
|
48
|
-
token: ${{ secrets.
|
|
48
|
+
token: ${{ secrets.GITHUB_TOKEN }}
|
|
49
49
|
|
|
50
50
|
- name: Install hatch
|
|
51
51
|
run: pipx install hatch
|
|
@@ -79,7 +79,7 @@ jobs:
|
|
|
79
79
|
if: ${{ github.ref == 'refs/heads/main' }}
|
|
80
80
|
uses: python-semantic-release/python-semantic-release@master
|
|
81
81
|
with:
|
|
82
|
-
github_token: ${{ secrets.
|
|
82
|
+
github_token: ${{ secrets.GITHUB_TOKEN }}
|
|
83
83
|
prerelease: ${{ env.PRERELEASE == 'true' }}
|
|
84
84
|
root_options: $DRY_RUN
|
|
85
85
|
|
|
@@ -17,8 +17,7 @@
|
|
|
17
17
|
"python.analysis.typeCheckingMode": "off",
|
|
18
18
|
|
|
19
19
|
"ruff.enable": true,
|
|
20
|
-
"ruff.
|
|
21
|
-
"ruff.lint.args": ["--config=pyproject.toml"],
|
|
20
|
+
"ruff.configuration": "pyproject.toml",
|
|
22
21
|
"ruff.importStrategy": "fromEnvironment",
|
|
23
22
|
"ruff.fixAll": true, //lint and fix all files in workspace
|
|
24
23
|
"ruff.organizeImports": true, //organize imports on save
|
|
@@ -1,7 +1,45 @@
|
|
|
1
1
|
# CHANGELOG
|
|
2
|
+
## v0.5.0 (2025-02-20)
|
|
3
|
+
|
|
4
|
+
## v0.5.0-beta.1 (2025-02-19)
|
|
5
|
+
|
|
6
|
+
### Features
|
|
7
|
+
|
|
8
|
+
* support `algopy.Array` and `algopy.ImmutableArray` from algorand-python 2.7 ([`fd8d19f`](https://github.com/algorandfoundation/algorand-python-testing/commit/fd8d19f25b9f8e0a48f58ae8f45e4d546b965f83))
|
|
9
|
+
|
|
10
|
+
* support mocking new `algopy.op` functions `falcon_verify`, `mimc`, `online_stake`, `sumhash512` and `VoterParamsGet` ([`83ddcbb`](https://github.com/algorandfoundation/algorand-python-testing/commit/83ddcbb8f83f72a5e0bc247c14e250c55496febf))
|
|
11
|
+
|
|
12
|
+
* update `algopy.op.Block` with fields added in AVM 11 ([`90d857d`](https://github.com/algorandfoundation/algorand-python-testing/commit/90d857d248d7b1b5a4b3791ccb0e10c20c478325))
|
|
13
|
+
|
|
14
|
+
* update `algopy.op.AcctParamsGet` with fields added in AVM 11 ([`059b669`](https://github.com/algorandfoundation/algorand-python-testing/commit/059b6690441e99a709fc47691bcb0e4f2453cd26))
|
|
15
|
+
|
|
16
|
+
* add `avm_version` to `algopy.Contract` class options ([`fc53b0f`](https://github.com/algorandfoundation/algorand-python-testing/commit/fc53b0fda5f0d22b6dbb99abf1ba024284fa52a4))
|
|
17
|
+
|
|
18
|
+
* update `algopy.op.Global` with fields added in AVM 11 ([`0cc9807`](https://github.com/algorandfoundation/algorand-python-testing/commit/0cc9807bbfc7084d54425c40889065ae2fd7d856))
|
|
19
|
+
|
|
20
|
+
* add `algopy.arc4.Struct._replace` introduced in algorand-python 2.5.0 ([`75d6847`](https://github.com/algorandfoundation/algorand-python-testing/commit/75d6847b80498d637c7f0b0e3915afd7af6f132c))
|
|
21
|
+
|
|
22
|
+
* add inline option to subroutine decorator ([`2cc15b3`](https://github.com/algorandfoundation/algorand-python-testing/commit/2cc15b3dc706eb8585b9658bf67b38da215e2e38))
|
|
23
|
+
|
|
24
|
+
### Bug fixes
|
|
25
|
+
|
|
26
|
+
* add missing mappings for `algopy.op.Txn` members ([`fddfe6f`](https://github.com/algorandfoundation/algorand-python-testing/commit/fddfe6f7ff9d6d4e0434f65e19dd0b0cf2aef6bd))
|
|
27
|
+
|
|
28
|
+
* include `ARC4Contract` in `algopy.arc4` namespace ([`f19d46f`](https://github.com/algorandfoundation/algorand-python-testing/commit/f19d46f5663c9fbe4e9b2e8c3bd1e2f7ddc89c3a))
|
|
29
|
+
|
|
30
|
+
* update `algopy.CompiledContract` and `algopy.CompiledLogicSig` to be NamedTuples ([`84be408`](https://github.com/algorandfoundation/algorand-python-testing/commit/84be4082348e3d89b40a65a69b599594a5531828))
|
|
31
|
+
|
|
32
|
+
* added missing __contains__ implementation for `algopy.Bytes` ([`8b2efa2`](https://github.com/algorandfoundation/algorand-python-testing/commit/8b2efa20b37e3043ac6a228d6706da4203373a7e))
|
|
33
|
+
|
|
34
|
+
### Documentation
|
|
35
|
+
|
|
36
|
+
* fix doctest example for `algopy.EllipticCurve` ([`7d0bb0d`](https://github.com/algorandfoundation/algorand-python-testing/commit/7d0bb0dfe9a5ea2d67b130fa300fb80cef52fda5))
|
|
37
|
+
|
|
38
|
+
## v0.4.1 (2024-09-03)
|
|
39
|
+
|
|
2
40
|
## v0.4.1-beta.1 (2024-09-03)
|
|
3
41
|
|
|
4
|
-
###
|
|
42
|
+
### Bug fixes
|
|
5
43
|
|
|
6
44
|
* ability to pass kw_only flag to dataclass when defining struct subclass (#23) ([`24bcf9d`](https://github.com/algorandfoundation/algorand-python-testing/commit/24bcf9d8af34eb2675ddf85ce9d71802f82f2d6a))
|
|
7
45
|
|
|
@@ -17,7 +55,7 @@
|
|
|
17
55
|
|
|
18
56
|
## v0.4.0-beta.1 (2024-08-27)
|
|
19
57
|
|
|
20
|
-
###
|
|
58
|
+
### Features
|
|
21
59
|
|
|
22
60
|
* add support for frozen on asset holdings, including a new ledger function `update_asset_holdings` for setting asset holding balances and frozen states ([`d777ca0`](https://github.com/algorandfoundation/algorand-python-testing/commit/d777ca0a318a8ade7a20363c9ce77fe8a8bf5d68))
|
|
23
61
|
|
|
@@ -27,7 +65,7 @@
|
|
|
27
65
|
|
|
28
66
|
* replaced `account_exists` with `account_is_funded` as the later is more useful ([`4d08690`](https://github.com/algorandfoundation/algorand-python-testing/commit/4d086903eb93a70ce1d485cdd7b12d8472ef16db))
|
|
29
67
|
|
|
30
|
-
###
|
|
68
|
+
### Bug fixes
|
|
31
69
|
|
|
32
70
|
* use correct type for Globals.caller_application_id ([`a30d85a`](https://github.com/algorandfoundation/algorand-python-testing/commit/a30d85a4416dfc2c5d901f3ace2265384ef60c01))
|
|
33
71
|
|
|
@@ -53,9 +91,9 @@
|
|
|
53
91
|
|
|
54
92
|
## v0.3.0-beta.8 (2024-08-22)
|
|
55
93
|
|
|
56
|
-
###
|
|
94
|
+
### Features
|
|
57
95
|
|
|
58
|
-
* include ARC4 results in log, and handle
|
|
96
|
+
* include ARC4 results in log, and handle > 15 ARC4 arguments (#18) ([`fd83ee8`](https://github.com/algorandfoundation/algorand-python-testing/commit/fd83ee8525a393d4a1a66f20acdb661906d84b51))
|
|
59
97
|
|
|
60
98
|
## v0.3.0-beta.7 (2024-08-21)
|
|
61
99
|
|
|
@@ -85,13 +123,13 @@
|
|
|
85
123
|
|
|
86
124
|
* chore: apply suggestions from code review
|
|
87
125
|
|
|
88
|
-
Co-authored-by: Daniel McGregor
|
|
126
|
+
Co-authored-by: Daniel McGregor <daniel.mcgregor@makerx.com.au>
|
|
89
127
|
|
|
90
128
|
* docs: addressing docs pr comments
|
|
91
129
|
|
|
92
130
|
## v0.3.0-beta.5 (2024-08-21)
|
|
93
131
|
|
|
94
|
-
###
|
|
132
|
+
### Bug fixes
|
|
95
133
|
|
|
96
134
|
* ensure mutable types (ARC4 tuple, array and structs) have their changes propagated back to container-like types (global/local state, boxes, ARC4 mutable types) (#14) ([`1f1f2ea`](https://github.com/algorandfoundation/algorand-python-testing/commit/1f1f2ea43a2f4f906cbcd5709b8e86b5c1f2bc63))
|
|
97
135
|
|
|
@@ -109,19 +147,19 @@
|
|
|
109
147
|
|
|
110
148
|
## v0.3.0-beta.4 (2024-08-21)
|
|
111
149
|
|
|
112
|
-
###
|
|
150
|
+
### Features
|
|
113
151
|
|
|
114
152
|
* rename txn_op_fields to active_txn_overrides to better reflect purpose, add additional checks to ensure crate_group parameters are used correctly ([`973fc28`](https://github.com/algorandfoundation/algorand-python-testing/commit/973fc288836d09ba4657642c980ca9f916d38823))
|
|
115
153
|
|
|
116
|
-
###
|
|
154
|
+
### Bug fixes
|
|
117
155
|
|
|
118
156
|
* fix equality implementation for Account, to allow comparison with arc4.Address ([`6ec2dd4`](https://github.com/algorandfoundation/algorand-python-testing/commit/6ec2dd4f2b4119987a5ea7c3c670bdd554c4fe30))
|
|
119
157
|
|
|
120
|
-
* ensure new Account
|
|
158
|
+
* ensure new Account's have field defaults populated ([`54432b0`](https://github.com/algorandfoundation/algorand-python-testing/commit/54432b03cef13008b16fab84dcc250824e2e2da1))
|
|
121
159
|
|
|
122
160
|
* ensure Global.current_application* properties match AVM ([`ae84ae2`](https://github.com/algorandfoundation/algorand-python-testing/commit/ae84ae27e49ef977babe7abb10d8994446d6b5f7))
|
|
123
161
|
|
|
124
|
-
* when generating app/asset id
|
|
162
|
+
* when generating app/asset id's skip any that might already be reserved ([`0bb5eba`](https://github.com/algorandfoundation/algorand-python-testing/commit/0bb5eba3ec75ffdb16cfbac5b3c4837f64f8a58a))
|
|
125
163
|
|
|
126
164
|
### Documentation
|
|
127
165
|
|
|
@@ -133,7 +171,7 @@
|
|
|
133
171
|
|
|
134
172
|
## v0.3.0-beta.1 (2024-08-14)
|
|
135
173
|
|
|
136
|
-
###
|
|
174
|
+
### Features
|
|
137
175
|
|
|
138
176
|
* deferred app calls, modular test context, refined access to value generators, numerous fixes/improvements (#4) ([`85dd58a`](https://github.com/algorandfoundation/algorand-python-testing/commit/85dd58a60f56a0737de84dcb549c01ca5a7a2851))
|
|
139
177
|
|
|
@@ -147,7 +185,7 @@
|
|
|
147
185
|
|
|
148
186
|
* chore: update src/algopy_testing/op.py
|
|
149
187
|
|
|
150
|
-
Co-authored-by: Daniel McGregor
|
|
188
|
+
Co-authored-by: Daniel McGregor <daniel.mcgregor@makerx.com.au>
|
|
151
189
|
|
|
152
190
|
* feat: adding acctparamsget; extra tests; pr comments
|
|
153
191
|
|
|
@@ -173,7 +211,7 @@
|
|
|
173
211
|
|
|
174
212
|
* remove lazy algopy imports from utils remove some unnecessary ignores add TODO
|
|
175
213
|
|
|
176
|
-
* simplify abimethod and add TODO
|
|
214
|
+
* simplify abimethod and add TODO's
|
|
177
215
|
|
|
178
216
|
* add TODO for state totals
|
|
179
217
|
|
|
@@ -187,7 +225,7 @@
|
|
|
187
225
|
|
|
188
226
|
* refactor: use implementation types in internal mappings
|
|
189
227
|
|
|
190
|
-
* refactor: remove usages of `import algopy` from op.py, remove explicit imports from typing module add TODO
|
|
228
|
+
* refactor: remove usages of `import algopy` from op.py, remove explicit imports from typing module add TODO's
|
|
191
229
|
|
|
192
230
|
* test: use non-abstract contract base
|
|
193
231
|
|
|
@@ -221,7 +259,7 @@
|
|
|
221
259
|
|
|
222
260
|
* test: adding tests for scratch slots
|
|
223
261
|
|
|
224
|
-
* refactor: renaming set_txn_fields
|
|
262
|
+
* refactor: renaming set_txn_fields -> scoped_txn_fields
|
|
225
263
|
|
|
226
264
|
* chore: adding `amount` field and open question under TODO;
|
|
227
265
|
|
|
@@ -243,7 +281,7 @@
|
|
|
243
281
|
|
|
244
282
|
* refactor: adding tests for ITxn, ITxnCreate and GITxn, fixing related bugs
|
|
245
283
|
|
|
246
|
-
* refactor: default_creator
|
|
284
|
+
* refactor: default_creator -> default_sender; setting creator as default_sender
|
|
247
285
|
|
|
248
286
|
* chore: parsing name to op name in ITxn
|
|
249
287
|
|
|
@@ -255,7 +293,7 @@
|
|
|
255
293
|
|
|
256
294
|
* add stricter type checks for primitives
|
|
257
295
|
|
|
258
|
-
* track when contracts are in a
|
|
296
|
+
* track when contracts are in a "creating" state or not
|
|
259
297
|
|
|
260
298
|
* todos
|
|
261
299
|
|
|
@@ -329,7 +367,7 @@
|
|
|
329
367
|
|
|
330
368
|
* chore: remove scoped_txn_fields methods
|
|
331
369
|
|
|
332
|
-
* add some additional TODO
|
|
370
|
+
* add some additional TODO's for scoped_execution
|
|
333
371
|
|
|
334
372
|
* remove TODO
|
|
335
373
|
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
Metadata-Version: 2.
|
|
1
|
+
Metadata-Version: 2.4
|
|
2
2
|
Name: algorand-python-testing
|
|
3
|
-
Version: 0.
|
|
3
|
+
Version: 0.5.0
|
|
4
4
|
Summary: Algorand Python testing library
|
|
5
5
|
Project-URL: Documentation, https://github.com/algorandfoundation/puya/tree/main/algopy_testing#README.md
|
|
6
6
|
Project-URL: Issues, https://github.com/algorandfoundation/puya/issues
|
|
@@ -48,7 +48,7 @@ Alternatively, if you want to start from scratch:
|
|
|
48
48
|
2. Install [AlgoKit CLI](https://github.com/algorandfoundation/algokit-cli?tab=readme-ov-file#install)
|
|
49
49
|
3. Install Algorand Python Testing into your project:
|
|
50
50
|
```bash
|
|
51
|
-
pip install algorand-testing
|
|
51
|
+
pip install algorand-python-testing
|
|
52
52
|
```
|
|
53
53
|
4. Create a test file (e.g., `test_contract.py`):
|
|
54
54
|
|
|
@@ -25,7 +25,7 @@ Alternatively, if you want to start from scratch:
|
|
|
25
25
|
2. Install [AlgoKit CLI](https://github.com/algorandfoundation/algokit-cli?tab=readme-ov-file#install)
|
|
26
26
|
3. Install Algorand Python Testing into your project:
|
|
27
27
|
```bash
|
|
28
|
-
pip install algorand-testing
|
|
28
|
+
pip install algorand-python-testing
|
|
29
29
|
```
|
|
30
30
|
4. Create a test file (e.g., `test_contract.py`):
|
|
31
31
|
|
{algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/docs/testing-guide/opcodes.md
RENAMED
|
@@ -353,20 +353,22 @@ test_mock_vrf_verify()
|
|
|
353
353
|
from unittest.mock import patch, MagicMock
|
|
354
354
|
import algopy
|
|
355
355
|
|
|
356
|
-
def
|
|
357
|
-
mock_result =
|
|
358
|
-
with patch('algopy.op.EllipticCurve.
|
|
359
|
-
result = algopy.op.EllipticCurve.
|
|
356
|
+
def test_mock_elliptic_curve_add():
|
|
357
|
+
mock_result = algopy.Bytes(b'result')
|
|
358
|
+
with patch('algopy.op.EllipticCurve.add', return_value=mock_result) as mock_add:
|
|
359
|
+
result = algopy.op.EllipticCurve.add(
|
|
360
360
|
algopy.op.EC.BN254g1,
|
|
361
|
-
algopy.Bytes(b'
|
|
361
|
+
algopy.Bytes(b'a'),
|
|
362
|
+
algopy.Bytes(b'b')
|
|
362
363
|
)
|
|
363
364
|
assert result == mock_result
|
|
364
|
-
|
|
365
|
+
mock_add.assert_called_once_with(
|
|
365
366
|
algopy.op.EC.BN254g1,
|
|
366
|
-
algopy.Bytes(b'
|
|
367
|
+
algopy.Bytes(b'a'),
|
|
368
|
+
algopy.Bytes(b'b'),
|
|
367
369
|
)
|
|
368
370
|
|
|
369
|
-
|
|
371
|
+
test_mock_elliptic_curve_add()
|
|
370
372
|
```
|
|
371
373
|
|
|
372
374
|
These examples demonstrate how to mock key mockable opcodes in `algorand-python-testing`. Use similar techniques (in your preferred testing framework) for other mockable opcodes like `algopy.compile_logicsig`, `algopy.arc4.arc4_create`, and `algopy.arc4.arc4_update`.
|
|
@@ -4,7 +4,7 @@ build-backend = "hatchling.build"
|
|
|
4
4
|
|
|
5
5
|
[project]
|
|
6
6
|
name = "algorand-python-testing"
|
|
7
|
-
version = "0.
|
|
7
|
+
version = "0.5.0"
|
|
8
8
|
description = 'Algorand Python testing library'
|
|
9
9
|
readme = "README.md"
|
|
10
10
|
requires-python = ">=3.12"
|
|
@@ -57,7 +57,7 @@ dependencies = [
|
|
|
57
57
|
"pytest-mock>=3.10.0",
|
|
58
58
|
"pytest-xdist[psutil]>=3.3",
|
|
59
59
|
"py-algorand-sdk>=2.4.0",
|
|
60
|
-
"algokit-utils>=
|
|
60
|
+
"algokit-utils>=3.0.0",
|
|
61
61
|
"pytest-cov>=4.1.0",
|
|
62
62
|
"prettytable>=3.9.0",
|
|
63
63
|
"mypy==1.10",
|
|
@@ -171,7 +171,7 @@ dependencies = [
|
|
|
171
171
|
"pytest-mock>=3.10.0",
|
|
172
172
|
"pytest-xdist[psutil]>=3.3",
|
|
173
173
|
"py-algorand-sdk>=2.4.0",
|
|
174
|
-
"algokit-utils>=
|
|
174
|
+
"algokit-utils>=3.0.0",
|
|
175
175
|
"pytest-cov>=4.1.0",
|
|
176
176
|
"mypy==1.10",
|
|
177
177
|
]
|
{algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/scripts/check_stubs_cov.py
RENAMED
|
@@ -1,7 +1,9 @@
|
|
|
1
1
|
import ast
|
|
2
|
+
import importlib
|
|
2
3
|
import inspect
|
|
3
4
|
import site
|
|
4
5
|
import sys
|
|
6
|
+
import typing
|
|
5
7
|
from collections.abc import Iterable
|
|
6
8
|
from pathlib import Path
|
|
7
9
|
from typing import NamedTuple
|
|
@@ -13,6 +15,40 @@ SITE_PACKAGES = Path(site.getsitepackages()[0])
|
|
|
13
15
|
STUBS_ROOT = SITE_PACKAGES / "algopy-stubs"
|
|
14
16
|
IMPL = PROJECT_ROOT / "src"
|
|
15
17
|
ROOT_MODULE = "algopy"
|
|
18
|
+
_ADDITIONAL_GLOBAL_IMPLS = [
|
|
19
|
+
"_algopy_testing.op.global_values._Global",
|
|
20
|
+
"_algopy_testing.op.global_values.GlobalFields",
|
|
21
|
+
]
|
|
22
|
+
_ADDITIONAL_TXN_IMPLS = [
|
|
23
|
+
"_algopy_testing.models.txn_fields.TransactionFields",
|
|
24
|
+
"_algopy_testing.models.txn_fields.TransactionFieldsGetter",
|
|
25
|
+
"_algopy_testing.op.constants.OP_MEMBER_TO_TXN_MEMBER",
|
|
26
|
+
]
|
|
27
|
+
|
|
28
|
+
# mapping of stub types to additional implementation types to scan for members
|
|
29
|
+
_ADDITIONAL_TYPE_IMPLS = {
|
|
30
|
+
"algopy.Asset": ["_algopy_testing.models.asset.AssetFields"],
|
|
31
|
+
"algopy.Account": ["_algopy_testing.models.account.AccountFields"],
|
|
32
|
+
"algopy.Application": ["_algopy_testing.models.application.ApplicationFields"],
|
|
33
|
+
"algopy.Global": _ADDITIONAL_GLOBAL_IMPLS,
|
|
34
|
+
"algopy.Txn": _ADDITIONAL_TXN_IMPLS,
|
|
35
|
+
"algopy.op.Global": _ADDITIONAL_GLOBAL_IMPLS,
|
|
36
|
+
"algopy.op.GTxn": _ADDITIONAL_TXN_IMPLS,
|
|
37
|
+
"algopy.op.GITxn": _ADDITIONAL_TXN_IMPLS,
|
|
38
|
+
"algopy.op.Txn": _ADDITIONAL_TXN_IMPLS,
|
|
39
|
+
"algopy.op.ITxn": _ADDITIONAL_TXN_IMPLS,
|
|
40
|
+
"algopy.op.ITxnCreate": _ADDITIONAL_TXN_IMPLS,
|
|
41
|
+
"algopy.op.AppParamsGet": ["_algopy_testing.op.misc._AppParamsGet"],
|
|
42
|
+
"algopy.op.AssetHoldingGet": ["_algopy_testing.op.misc._AssetHoldingGet"],
|
|
43
|
+
"algopy.op.AppGlobal": ["_algopy_testing.op.misc._AppGlobal"],
|
|
44
|
+
"algopy.op.AppLocal": ["_algopy_testing.op.misc._AppLocal"],
|
|
45
|
+
"algopy.op.Scratch": ["_algopy_testing.op.misc._Scratch"],
|
|
46
|
+
}
|
|
47
|
+
|
|
48
|
+
# mapping of stub types to members that may be present but not found when discovering members
|
|
49
|
+
_ADDITIONAL_MEMBERS = {
|
|
50
|
+
"algopy.Asset": ["id"],
|
|
51
|
+
}
|
|
16
52
|
|
|
17
53
|
|
|
18
54
|
class ASTNodeDefinition(NamedTuple):
|
|
@@ -127,9 +163,6 @@ def collect_stubs(stubs_dir: Path, relative_module: str) -> dict[str, ASTNodeDef
|
|
|
127
163
|
def collect_coverage(stubs: dict[str, ASTNodeDefinition]) -> list[CoverageResult]:
|
|
128
164
|
result = []
|
|
129
165
|
for full_name, stub in stubs.items():
|
|
130
|
-
if "GTxn" in full_name:
|
|
131
|
-
print("stop")
|
|
132
|
-
|
|
133
166
|
coverage = _get_impl_coverage(full_name, stub)
|
|
134
167
|
if coverage:
|
|
135
168
|
try:
|
|
@@ -145,7 +178,7 @@ def collect_coverage(stubs: dict[str, ASTNodeDefinition]) -> list[CoverageResult
|
|
|
145
178
|
CoverageResult(
|
|
146
179
|
full_name=full_name,
|
|
147
180
|
stub_file=str(stub.path.relative_to(STUBS_ROOT)),
|
|
148
|
-
impl_file=impl_file,
|
|
181
|
+
impl_file=impl_file or "MISSING!",
|
|
149
182
|
coverage=coverage.coverage if coverage else 0,
|
|
150
183
|
missing=", ".join(coverage.missing if coverage else []),
|
|
151
184
|
)
|
|
@@ -156,18 +189,16 @@ def collect_coverage(stubs: dict[str, ASTNodeDefinition]) -> list[CoverageResult
|
|
|
156
189
|
def print_results(results: list[CoverageResult]) -> None:
|
|
157
190
|
table = PrettyTable(
|
|
158
191
|
field_names=["Name", "Implementation", "Source Stub", "Coverage", "Missing"],
|
|
159
|
-
sortby="Coverage",
|
|
160
192
|
header=True,
|
|
161
193
|
border=True,
|
|
162
194
|
padding_width=2,
|
|
163
|
-
reversesort=True,
|
|
164
195
|
left_padding_width=0,
|
|
165
196
|
right_padding_width=1,
|
|
166
197
|
align="l",
|
|
167
198
|
max_width=100,
|
|
168
199
|
)
|
|
169
200
|
|
|
170
|
-
for result in results:
|
|
201
|
+
for result in sorted(results, key=lambda c: c.coverage):
|
|
171
202
|
table.add_row(
|
|
172
203
|
[
|
|
173
204
|
result.full_name,
|
|
@@ -209,7 +240,6 @@ def _get_impl_coverage(symbol: str, stub: ASTNodeDefinition) -> ImplCoverage | N
|
|
|
209
240
|
try:
|
|
210
241
|
impl = getattr(mod, name)
|
|
211
242
|
except AttributeError:
|
|
212
|
-
print(f"Attribute {name} not found in module {module}")
|
|
213
243
|
return None
|
|
214
244
|
|
|
215
245
|
try:
|
|
@@ -219,20 +249,6 @@ def _get_impl_coverage(symbol: str, stub: ASTNodeDefinition) -> ImplCoverage | N
|
|
|
219
249
|
if hasattr(impl, "__class__"):
|
|
220
250
|
try:
|
|
221
251
|
impl_path = Path(inspect.getfile(impl.__class__))
|
|
222
|
-
# For special cases like GTxn and GITxn, assume full implementation
|
|
223
|
-
if name in [
|
|
224
|
-
"GTxn",
|
|
225
|
-
"GITxn",
|
|
226
|
-
"Txn",
|
|
227
|
-
"ITxn",
|
|
228
|
-
"Global",
|
|
229
|
-
"AssetConfigInnerTransaction",
|
|
230
|
-
"Contract",
|
|
231
|
-
"ApplicationCallInnerTransaction",
|
|
232
|
-
"UFixedNxM",
|
|
233
|
-
"BigUFixedNxM",
|
|
234
|
-
]:
|
|
235
|
-
return ImplCoverage(impl_path)
|
|
236
252
|
except TypeError:
|
|
237
253
|
print(f"Warning: Could not determine file for {symbol}")
|
|
238
254
|
return None
|
|
@@ -240,18 +256,56 @@ def _get_impl_coverage(symbol: str, stub: ASTNodeDefinition) -> ImplCoverage | N
|
|
|
240
256
|
print(f"Warning: Could not determine file for {symbol}")
|
|
241
257
|
return None
|
|
242
258
|
|
|
243
|
-
return _compare_stub_impl(stub.node, impl, impl_path)
|
|
259
|
+
return _compare_stub_impl(stub.node, symbol, impl, impl_path)
|
|
260
|
+
|
|
261
|
+
|
|
262
|
+
def _get_impl_members(impl_name: str, impl: object) -> set[str]:
|
|
263
|
+
if isinstance(impl, type):
|
|
264
|
+
impl_mros: list[object] = [
|
|
265
|
+
typ for typ in impl.mro() if typ.__module__.startswith("_algopy_testing")
|
|
266
|
+
]
|
|
267
|
+
else:
|
|
268
|
+
impl_mros = []
|
|
269
|
+
for additional_type in _ADDITIONAL_TYPE_IMPLS.get(impl_name, []):
|
|
270
|
+
impl_mros.append(_resolve_fullname(additional_type))
|
|
271
|
+
|
|
272
|
+
impl_members = set[str](_ADDITIONAL_MEMBERS.get(impl_name, []))
|
|
273
|
+
for impl_typ in impl_mros:
|
|
274
|
+
if typing.is_typeddict(impl_typ) and isinstance(impl_typ, type):
|
|
275
|
+
for typed_dict_mro in impl_typ.mro():
|
|
276
|
+
ann = getattr(typed_dict_mro, "__annotations__", None)
|
|
277
|
+
if isinstance(ann, dict):
|
|
278
|
+
impl_members.update(ann.keys())
|
|
279
|
+
elif isinstance(impl_typ, dict):
|
|
280
|
+
impl_members.update(impl_typ.keys())
|
|
281
|
+
elif isinstance(impl_typ, type):
|
|
282
|
+
members = list(vars(impl_typ).keys())
|
|
283
|
+
impl_members.update(members)
|
|
284
|
+
else:
|
|
285
|
+
raise ValueError(f"unexpected implementation type, {impl_typ}")
|
|
286
|
+
# special case for ITxnCreate
|
|
287
|
+
if impl_name == "algopy.op.ITxnCreate":
|
|
288
|
+
impl_members = {f"set_{member}" for member in impl_members}
|
|
289
|
+
impl_members.update(("begin", "next", "submit"))
|
|
290
|
+
return impl_members
|
|
291
|
+
|
|
244
292
|
|
|
293
|
+
def _resolve_fullname(fullname: str) -> object:
|
|
294
|
+
# note this assumes no nested classes
|
|
295
|
+
module_name, type_name = fullname.rsplit(".", maxsplit=1)
|
|
296
|
+
module = importlib.import_module(module_name)
|
|
297
|
+
return getattr(module, type_name)
|
|
245
298
|
|
|
246
|
-
|
|
299
|
+
|
|
300
|
+
def _compare_stub_impl(
|
|
301
|
+
stub: ast.AST, impl_name: str, impl: object, impl_path: Path
|
|
302
|
+
) -> ImplCoverage:
|
|
247
303
|
# classes are really the only types that can be "partially implemented"
|
|
248
304
|
# from a typing perspective
|
|
249
|
-
|
|
305
|
+
# algopy.uenumerate is typed as a class, but is really just a function
|
|
306
|
+
if not isinstance(stub, ast.ClassDef) or impl_name == "algopy.uenumerate":
|
|
250
307
|
return ImplCoverage(impl_path)
|
|
251
|
-
|
|
252
|
-
# using vars to only get explicitly implemented members
|
|
253
|
-
# need more sophisticated approach if implementations start using inheritance
|
|
254
|
-
impl_members = set(vars(impl))
|
|
308
|
+
impl_members = _get_impl_members(impl_name, impl)
|
|
255
309
|
stub_members = set()
|
|
256
310
|
for stmt in stub.body:
|
|
257
311
|
if isinstance(stmt, ast.FunctionDef):
|
|
@@ -287,6 +341,8 @@ def _compare_stub_impl(stub: ast.AST, impl: object, impl_path: Path) -> ImplCove
|
|
|
287
341
|
"ne",
|
|
288
342
|
)
|
|
289
343
|
}
|
|
344
|
+
# excluding special fields used in typing hints
|
|
345
|
+
default_impls.update(("__match_args__", "__match_value__"))
|
|
290
346
|
missing = sorted(stub_members.difference({*impl_members, *default_impls}))
|
|
291
347
|
return ImplCoverage(impl_path, sorted(stub_members), missing)
|
|
292
348
|
|
{algorand_python_testing-0.4.1b1 → algorand_python_testing-0.5.0}/scripts/refresh_test_artifacts.py
RENAMED
|
@@ -16,13 +16,13 @@ ENV_WITH_NO_COLOR = dict(os.environ) | {
|
|
|
16
16
|
|
|
17
17
|
def get_artifact_folders(root_dir: str) -> Iterator[Path]:
|
|
18
18
|
for folder in Path(root_dir).iterdir():
|
|
19
|
-
if folder.is_dir() and (folder
|
|
19
|
+
if folder.is_dir() and not str(folder.stem).startswith((".", "__")):
|
|
20
20
|
yield folder
|
|
21
21
|
|
|
22
22
|
|
|
23
23
|
def compile_contract(folder: Path) -> None:
|
|
24
24
|
logger.info(f"Compiling: {folder}")
|
|
25
|
-
contract_path = folder
|
|
25
|
+
contract_path = folder
|
|
26
26
|
(folder / "data").mkdir(exist_ok=True)
|
|
27
27
|
compile_cmd = [
|
|
28
28
|
"hatch",
|