Skip to content

Commit

Permalink
Merge branch 'master' into docs/pipx-install
Browse files Browse the repository at this point in the history
  • Loading branch information
charles-cooper authored Oct 5, 2024
2 parents ad01caf + 02f8654 commit a11be86
Show file tree
Hide file tree
Showing 32 changed files with 515 additions and 216 deletions.
10 changes: 5 additions & 5 deletions tests/functional/builtins/codegen/test_empty.py
Original file line number Diff line number Diff line change
Expand Up @@ -672,11 +672,11 @@ def test_empty_array_in_event_logging(get_contract, get_logs):
@external
def foo():
log MyLog(
b'hellohellohellohellohellohellohellohellohello',
empty(int128[2][3]),
314159,
b'helphelphelphelphelphelphelphelphelphelphelp',
empty(uint256[3])
arg1=b'hellohellohellohellohellohellohellohellohello',
arg2=empty(int128[2][3]),
arg3=314159,
arg4=b'helphelphelphelphelphelphelphelphelphelphelp',
arg5=empty(uint256[3])
)
"""

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ def test_basic_default(env, get_logs, get_contract):
@external
@payable
def __default__():
log Sent(msg.sender)
log Sent(sender=msg.sender)
"""
c = get_contract(code)
env.set_balance(env.deployer, 10**18)
Expand All @@ -46,13 +46,13 @@ def test_basic_default_default_param_function(env, get_logs, get_contract):
@external
@payable
def fooBar(a: int128 = 12345) -> int128:
log Sent(empty(address))
log Sent(sender=empty(address))
return a
@external
@payable
def __default__():
log Sent(msg.sender)
log Sent(sender=msg.sender)
"""
c = get_contract(code)
env.set_balance(env.deployer, 10**18)
Expand All @@ -69,7 +69,7 @@ def test_basic_default_not_payable(env, tx_failed, get_contract):
@external
def __default__():
log Sent(msg.sender)
log Sent(sender=msg.sender)
"""
c = get_contract(code)
env.set_balance(env.deployer, 10**17)
Expand Down Expand Up @@ -103,7 +103,7 @@ def test_always_public_2(assert_compile_failed, get_contract):
sender: indexed(address)
def __default__():
log Sent(msg.sender)
log Sent(sender=msg.sender)
"""
assert_compile_failed(lambda: get_contract(code))

Expand All @@ -119,12 +119,12 @@ def test_zero_method_id(env, get_logs, get_contract, tx_failed):
@payable
# function selector: 0x00000000
def blockHashAskewLimitary(v: uint256) -> uint256:
log Sent(2)
log Sent(sig=2)
return 7
@external
def __default__():
log Sent(1)
log Sent(sig=1)
"""
c = get_contract(code)

Expand Down Expand Up @@ -165,12 +165,12 @@ def test_another_zero_method_id(env, get_logs, get_contract, tx_failed):
@payable
# function selector: 0x00000000
def wycpnbqcyf() -> uint256:
log Sent(2)
log Sent(sig=2)
return 7
@external
def __default__():
log Sent(1)
log Sent(sig=1)
"""
c = get_contract(code)

Expand Down Expand Up @@ -205,12 +205,12 @@ def test_partial_selector_match_trailing_zeroes(env, get_logs, get_contract):
@payable
# function selector: 0xd88e0b00
def fow() -> uint256:
log Sent(2)
log Sent(sig=2)
return 7
@external
def __default__():
log Sent(1)
log Sent(sig=1)
"""
c = get_contract(code)

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -436,7 +436,7 @@ def i_am_me() -> bool:
@external
@nonpayable
def whoami() -> address:
log Addr(self._whoami())
log Addr(addr=self._whoami())
return self._whoami()
"""

Expand Down
Loading

0 comments on commit a11be86

Please sign in to comment.