diff --git a/tests/solidity_contract_test.py b/tests/solidity_contract_test.py index 87023116..a90faca5 100644 --- a/tests/solidity_contract_test.py +++ b/tests/solidity_contract_test.py @@ -12,7 +12,7 @@ class SolidityContractTest(BaseTestCase): input_file = TEST_FILES / "multi_contracts.sol" contract = SolidityContract(str(input_file)) - code_info = contract.get_source_info(142) + code_info = contract.get_source_info(109) self.assertEqual(code_info.filename, str(input_file)) self.assertEqual(code_info.lineno, 14) @@ -22,7 +22,7 @@ class SolidityContractTest(BaseTestCase): input_file = TEST_FILES / "multi_contracts.sol" contract = SolidityContract(str(input_file), name="Transfer1") - code_info = contract.get_source_info(142) + code_info = contract.get_source_info(109) self.assertEqual(code_info.filename, str(input_file)) self.assertEqual(code_info.lineno, 6) @@ -32,7 +32,7 @@ class SolidityContractTest(BaseTestCase): input_file = TEST_FILES / "constructor_assert.sol" contract = SolidityContract(str(input_file), name="AssertFail") - code_info = contract.get_source_info(70, constructor=True) + code_info = contract.get_source_info(75, constructor=True) self.assertEqual(code_info.filename, str(input_file)) self.assertEqual(code_info.lineno, 6) diff --git a/tests/testdata/input_contracts/calls.sol b/tests/testdata/input_contracts/calls.sol index cc7998ee..9c1222c9 100644 --- a/tests/testdata/input_contracts/calls.sol +++ b/tests/testdata/input_contracts/calls.sol @@ -1,4 +1,4 @@ -pragma solidity 0.5.0; +pragma solidity ^0.5.0; contract Caller { diff --git a/tests/testdata/input_contracts/constructor_assert.sol b/tests/testdata/input_contracts/constructor_assert.sol index fa1e7018..37877a2b 100644 --- a/tests/testdata/input_contracts/constructor_assert.sol +++ b/tests/testdata/input_contracts/constructor_assert.sol @@ -1,4 +1,4 @@ -pragma solidity 0.5.0; +pragma solidity ^0.5.0; contract AssertFail { diff --git a/tests/testdata/input_contracts/environments.sol b/tests/testdata/input_contracts/environments.sol index 4a3a66a4..c872e9a9 100644 --- a/tests/testdata/input_contracts/environments.sol +++ b/tests/testdata/input_contracts/environments.sol @@ -1,4 +1,4 @@ -pragma solidity 0.5.0; +pragma solidity ^0.5.0; contract IntegerOverflow2 { diff --git a/tests/testdata/input_contracts/ether_send.sol b/tests/testdata/input_contracts/ether_send.sol index 59e1e245..ce70a9f4 100644 --- a/tests/testdata/input_contracts/ether_send.sol +++ b/tests/testdata/input_contracts/ether_send.sol @@ -1,4 +1,5 @@ -pragma solidity 0.5.0; +pragma solidity ^0.5.0; + contract Crowdfunding { diff --git a/tests/testdata/input_contracts/exceptions.sol b/tests/testdata/input_contracts/exceptions.sol index aa925603..89425589 100644 --- a/tests/testdata/input_contracts/exceptions.sol +++ b/tests/testdata/input_contracts/exceptions.sol @@ -1,4 +1,4 @@ -pragma solidity 0.5.0; +pragma solidity ^0.5.0; contract Exceptions { diff --git a/tests/testdata/input_contracts/kinds_of_calls.sol b/tests/testdata/input_contracts/kinds_of_calls.sol index 2b1cb8c4..36b8d61d 100644 --- a/tests/testdata/input_contracts/kinds_of_calls.sol +++ b/tests/testdata/input_contracts/kinds_of_calls.sol @@ -1,4 +1,4 @@ -pragma solidity 0.5.0; +pragma solidity ^0.5.0; contract D { diff --git a/tests/testdata/input_contracts/metacoin.sol b/tests/testdata/input_contracts/metacoin.sol index 557c0d11..846425ad 100644 --- a/tests/testdata/input_contracts/metacoin.sol +++ b/tests/testdata/input_contracts/metacoin.sol @@ -1,4 +1,4 @@ -pragma solidity 0.5.0; +pragma solidity ^0.5.0; contract MetaCoin { diff --git a/tests/testdata/input_contracts/multi_contracts.sol b/tests/testdata/input_contracts/multi_contracts.sol index c8c4e76a..e2ac1506 100644 --- a/tests/testdata/input_contracts/multi_contracts.sol +++ b/tests/testdata/input_contracts/multi_contracts.sol @@ -1,4 +1,4 @@ -pragma solidity 0.5.0; +pragma solidity ^0.5.0; contract Transfer1 { diff --git a/tests/testdata/input_contracts/nonascii.sol b/tests/testdata/input_contracts/nonascii.sol index d8a28a61..f660f105 100644 --- a/tests/testdata/input_contracts/nonascii.sol +++ b/tests/testdata/input_contracts/nonascii.sol @@ -1,8 +1,8 @@ -pragma solidity 0.5.0; +pragma solidity ^0.5.0; contract nonAscii { function renderNonAscii () public pure returns (string memory) { return "Хэллоу Ворлд"; } -} \ No newline at end of file +} diff --git a/tests/testdata/input_contracts/origin.sol b/tests/testdata/input_contracts/origin.sol index 2ceb10f8..44bdd19b 100644 --- a/tests/testdata/input_contracts/origin.sol +++ b/tests/testdata/input_contracts/origin.sol @@ -1,4 +1,4 @@ -pragma solidity 0.5.0; +pragma solidity ^0.5.0; contract Origin { diff --git a/tests/testdata/input_contracts/overflow.sol b/tests/testdata/input_contracts/overflow.sol index 5c88e847..ee94c4c6 100644 --- a/tests/testdata/input_contracts/overflow.sol +++ b/tests/testdata/input_contracts/overflow.sol @@ -1,3 +1,4 @@ +pragma solidity ^0.5.0; contract Over { diff --git a/tests/testdata/input_contracts/returnvalue.sol b/tests/testdata/input_contracts/returnvalue.sol index 88bd8805..f10a12f7 100644 --- a/tests/testdata/input_contracts/returnvalue.sol +++ b/tests/testdata/input_contracts/returnvalue.sol @@ -1,4 +1,4 @@ -pragma solidity 0.5.0; +pragma solidity ^0.5.0; contract ReturnValue { @@ -14,4 +14,4 @@ contract ReturnValue { require(success); } -} \ No newline at end of file +} diff --git a/tests/testdata/input_contracts/rubixi.sol b/tests/testdata/input_contracts/rubixi.sol index 8e1567c6..e919d237 100644 --- a/tests/testdata/input_contracts/rubixi.sol +++ b/tests/testdata/input_contracts/rubixi.sol @@ -1,4 +1,4 @@ -pragma solidity 0.5.0; +pragma solidity ^0.5.0; contract Rubixi { diff --git a/tests/testdata/input_contracts/suicide.sol b/tests/testdata/input_contracts/suicide.sol index 4c77157b..658da2d7 100644 --- a/tests/testdata/input_contracts/suicide.sol +++ b/tests/testdata/input_contracts/suicide.sol @@ -1,4 +1,4 @@ -pragma solidity 0.5.0; +pragma solidity ^0.5.0; contract Suicide { diff --git a/tests/testdata/input_contracts/underflow.sol b/tests/testdata/input_contracts/underflow.sol index 01ed4ef9..6172a107 100644 --- a/tests/testdata/input_contracts/underflow.sol +++ b/tests/testdata/input_contracts/underflow.sol @@ -1,4 +1,4 @@ -pragma solidity 0.5.0; +pragma solidity ^0.5.0; contract Under { @@ -20,4 +20,4 @@ contract Under { function balanceOf(address _owner) public view returns (uint balance) { return balances[_owner]; } -} \ No newline at end of file +} diff --git a/tests/testdata/input_contracts/weak_random.sol b/tests/testdata/input_contracts/weak_random.sol index 5acdd7ef..4433d515 100644 --- a/tests/testdata/input_contracts/weak_random.sol +++ b/tests/testdata/input_contracts/weak_random.sol @@ -1,4 +1,4 @@ -pragma solidity 0.5.0; +pragma solidity ^0.5.0; contract WeakRandom {