File tree Expand file tree Collapse file tree 2 files changed +4
-2
lines changed Expand file tree Collapse file tree 2 files changed +4
-2
lines changed Original file line number Diff line number Diff line change @@ -191,7 +191,7 @@ def _pragmas(self) -> str:
191
191
ret += f"pragma solidity { self ._pragma_solidity } ;\n "
192
192
else :
193
193
# TODO support multiple compiler version
194
- ret += f"pragma solidity { self ._slither .crytic_compile .compilation_units [0 ].compiler_version .version } ;\n "
194
+ ret += f"pragma solidity { list ( self ._slither .crytic_compile .compilation_units . values ()) [0 ].compiler_version .version } ;\n "
195
195
196
196
if self ._use_abi_encoder_v2 :
197
197
ret += "pragma experimental ABIEncoderV2;\n "
Original file line number Diff line number Diff line change @@ -245,7 +245,9 @@ def test_functions():
245
245
def test_function_can_send_eth ():
246
246
slither = Slither ("tests/test_function.sol" )
247
247
compilation_unit = slither .compilation_units [0 ]
248
- functions = compilation_unit .contracts_as_dict ["TestFunctionCanSendEth" ].available_functions_as_dict ()
248
+ functions = compilation_unit .contracts_as_dict [
249
+ "TestFunctionCanSendEth"
250
+ ].available_functions_as_dict ()
249
251
250
252
assert functions ["send_direct()" ].can_send_eth () is True
251
253
assert functions ["transfer_direct()" ].can_send_eth () is True
You can’t perform that action at this time.
0 commit comments