watcher-ts/packages/solidity-mapper/test/contracts/TestBooleans.sol
Ashwin Phatak 72ca980198
Solidity data mapper/parser (#12)
* Initial setup with hardhat and typescript.

* Add test for integer type.

* Add test for unsigned integer type.

* Add test for boolean type.

* Add test for address type.

* Add test for string type.

* Setup building library with typescript.

* Remove hardhat dependency from getStorageValue library function.

* Move contracts to test and remove deploy script.

* Add readme for running tests.

Co-authored-by: nikugogoi <95nikass@gmail.com>
2021-05-31 11:07:11 +05:30

19 lines
410 B
Solidity

// SPDX-License-Identifier: MIT
pragma solidity ^0.7.0;
contract TestBooleans {
// Variables are packed together in a slot as they occupy less than 32 bytes together.
bool bool1;
bool bool2;
// Set variable bool1.
function setBool1(bool value) external {
bool1 = value;
}
// Set variable bool2.
function setBool2(bool value) external {
bool2 = value;
}
}