Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

contracts: silence SIWE Solidity tests compile warnings #360

Merged
merged 2 commits into from
Aug 26, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion clients/py/requirements.txt
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
cbor2
pynacl
web3
web3==6.*
14 changes: 7 additions & 7 deletions contracts/contracts/tests/SiweParserTests.sol
Original file line number Diff line number Diff line change
Expand Up @@ -6,47 +6,47 @@ import {ParsedSiweMessage, SiweParser} from "../SiweParser.sol";
contract SiweParserTests {
function testHexStringToAddress(bytes memory addr)
external
view
pure
returns (address)
{
return SiweParser._hexStringToAddress(addr);
}

function testFromHexChar(uint8 c) external view returns (uint8) {
function testFromHexChar(uint8 c) external pure returns (uint8) {
return SiweParser._fromHexChar(c);
}

function testSubstr(
bytes memory str,
uint256 startIndex,
uint256 endIndex
) external view returns (bytes memory) {
) external pure returns (bytes memory) {
return SiweParser._substr(str, startIndex, endIndex);
}

function testParseUint(bytes memory b) external view returns (uint256) {
function testParseUint(bytes memory b) external pure returns (uint256) {
return SiweParser._parseUint(b);
}

function testParseField(
bytes calldata str,
string memory name,
uint256 i
) external view returns (bytes memory value, uint256) {
) external pure returns (bytes memory value, uint256) {
return SiweParser._parseField(str, name, i);
}

function testParseArray(bytes calldata str, uint256 i)
external
view
pure
returns (bytes[] memory values, uint256 count)
{
return SiweParser._parseArray(str, i);
}

function testParseSiweMsg(bytes calldata siweMsg)
external
view
pure
returns (ParsedSiweMessage memory)
{
return SiweParser.parseSiweMsg(siweMsg);
Expand Down
Loading