aboutsummaryrefslogtreecommitdiffstats
path: root/packages/contracts/src
diff options
context:
space:
mode:
authorRemco Bloemen <remco@wicked.ventures>2018-06-14 00:12:45 +0800
committerRemco Bloemen <remco@wicked.ventures>2018-06-23 19:53:38 +0800
commit384cd2f6059bba994a6af2992a7df4909e24897c (patch)
treefa4f1ca39a91457b290e3c3c748a7cb3e724b10b /packages/contracts/src
parent425af46f98c83e2796aaf0b946d250193393754c (diff)
downloaddexon-0x-contracts-384cd2f6059bba994a6af2992a7df4909e24897c.tar
dexon-0x-contracts-384cd2f6059bba994a6af2992a7df4909e24897c.tar.gz
dexon-0x-contracts-384cd2f6059bba994a6af2992a7df4909e24897c.tar.bz2
dexon-0x-contracts-384cd2f6059bba994a6af2992a7df4909e24897c.tar.lz
dexon-0x-contracts-384cd2f6059bba994a6af2992a7df4909e24897c.tar.xz
dexon-0x-contracts-384cd2f6059bba994a6af2992a7df4909e24897c.tar.zst
dexon-0x-contracts-384cd2f6059bba994a6af2992a7df4909e24897c.zip
Add trailing garbage testcase for LibBytes.equals
Diffstat (limited to 'packages/contracts/src')
-rw-r--r--packages/contracts/src/contracts/current/test/TestLibBytes/TestLibBytes.sol11
1 files changed, 11 insertions, 0 deletions
diff --git a/packages/contracts/src/contracts/current/test/TestLibBytes/TestLibBytes.sol b/packages/contracts/src/contracts/current/test/TestLibBytes/TestLibBytes.sol
index 60ee3db7f..d14022a64 100644
--- a/packages/contracts/src/contracts/current/test/TestLibBytes/TestLibBytes.sol
+++ b/packages/contracts/src/contracts/current/test/TestLibBytes/TestLibBytes.sol
@@ -61,6 +61,17 @@ contract TestLibBytes {
equal = lhs.equals(rhs);
return equal;
}
+
+ function publicEqualsPop1(bytes memory lhs, bytes memory rhs)
+ public
+ pure
+ returns (bool equal)
+ {
+ lhs.popByte();
+ rhs.popByte();
+ equal = lhs.equals(rhs);
+ return equal;
+ }
/// @dev Performs a deep copy of a byte array onto another byte array of greater than or equal length.
/// @param dest Byte array that will be overwritten with source bytes.