diff --git a/pyteal/compiler/compiler.py b/pyteal/compiler/compiler.py index 1644e8343..dc1199e45 100644 --- a/pyteal/compiler/compiler.py +++ b/pyteal/compiler/compiler.py @@ -22,7 +22,7 @@ ) from .constants import createConstantBlocks -MAX_TEAL_VERSION = 5 +MAX_TEAL_VERSION = 6 MIN_TEAL_VERSION = 2 DEFAULT_TEAL_VERSION = MIN_TEAL_VERSION diff --git a/pyteal/compiler/compiler_test.py b/pyteal/compiler/compiler_test.py index 3679be27b..815117337 100644 --- a/pyteal/compiler/compiler_test.py +++ b/pyteal/compiler/compiler_test.py @@ -134,7 +134,7 @@ def test_compile_version_invalid(): compileTeal(expr, Mode.Signature, version=1) # too small with pytest.raises(TealInputError): - compileTeal(expr, Mode.Signature, version=6) # too large + compileTeal(expr, Mode.Signature, version=7) # too large with pytest.raises(TealInputError): compileTeal(expr, Mode.Signature, version=2.0) # decimal @@ -195,6 +195,17 @@ def test_compile_version_5(): assert actual == expected +def test_compile_version_6(): + expr = Int(1) + expected = """ +#pragma version 6 +int 1 +return +""".strip() + actual = compileTeal(expr, Mode.Signature, version=6) + assert actual == expected + + def test_slot_load_before_store(): program = AssetHolding.balance(Int(0), Int(0)).value()