Commit Graph

69 Commits

Author SHA1 Message Date
Fabio Berger
27670f4da6 Rename RevertReasons to RevertReason since singular enum names are more common 2018-06-26 08:11:14 +02:00
Fabio Berger
f811c07454 Move RevertReasons to @0xproject/types package 2018-06-25 12:59:26 +02:00
Fabio Berger
df79fb19af Merge branch 'v2-prototype' into refactor/check-revert-reasons
* v2-prototype: (48 commits)
  Fix typos in comments
  Add modifier and tests for removeAuthorizedAddressAtIndex
  Update and add tests
  Change removeAuthorizedAddress => removeAuthorizedAddressAtIndex
  Move isFunctionRemoveAuthorizedAddress to test
  Fix usage of `popLastByte`
  Fix LibBytes is a library
  Remove `areBytesEqual`
  Fix usage of `contentAddress()`
  Clean low bits in bytes4
  Clean high bits in address
  Refactor LibBytes.readBytes4 for consistency
  Fix LibBytes.equals
  Add trailing garbage testcase for LibBytes.equals
  Rename bytes.equals
  Add slice and sliceDestructive
  Rename bytes.rawAddress and add bytes.contentAddress
  Rename read/writeBytesWithLength
  Using LibBytes for bytes
  Make LibBytes a library
  ...

# Conflicts:
#	packages/contracts/src/contracts/current/utils/Ownable/Ownable.sol
#	packages/contracts/test/libraries/lib_bytes.ts
2018-06-25 11:45:17 +02:00
Amir Bandeali
8ddcb6c841 Update and add tests 2018-06-23 13:53:39 +02:00
Remco Bloemen
943e556f43 Refactor LibBytes.readBytes4 for consistency 2018-06-23 13:53:38 +02:00
Remco Bloemen
384cd2f605 Add trailing garbage testcase for LibBytes.equals 2018-06-23 13:53:38 +02:00
Remco Bloemen
425af46f98 Rename bytes.equals 2018-06-23 13:53:38 +02:00
Remco Bloemen
88982f98ff Rename read/writeBytesWithLength 2018-06-23 13:53:38 +02:00
Remco Bloemen
7f84049538 Merge LibMem and LibBytes 2018-06-23 13:53:38 +02:00
Remco Bloemen
98840c9c5f Use provided mem in refernce memcpy 2018-06-23 13:53:38 +02:00
Fabio Berger
1e03fbe1a8 Fix prettier 2018-06-22 18:50:02 +02:00
Fabio Berger
4409f11b24 Rename ContractLibErrors to RevertReasons 2018-06-22 18:45:45 +02:00
Fabio Berger
0e7c254b93 Move constants over to ContractLibError enum and update all tests 2018-06-22 18:36:15 +02:00
Amir Bandeali
0917fa0d75 Rename popByte and popAddress 2018-06-12 15:30:46 -07:00
Amir Bandeali
cfb73dd534 Hard code test addresses/bytes32 instead of generating pseudorandom ones 2018-06-12 15:30:46 -07:00
Amir Bandeali
764b1c35cb Add tests for deepCopyBytes and missing write methods from LibBytes 2018-06-12 11:45:02 -07:00
Fabio Berger
e1879ef4d9 Fix no-unused-variable tslint rule to include parameters and fix issues 2018-06-11 23:42:30 +02:00
Greg Hysen
05fbc8e6b0 Linter changes to contracts 2018-06-08 11:43:47 -07:00
Greg Hysen
05123ea6f4 Updated LibBytes error messages 2018-06-07 16:32:42 -07:00
Greg Hysen
d62ff34a5a Cleanup after last rebase 2018-06-07 15:53:30 -07:00
Greg Hysen
0d4ff5a916 Updated tests to use new revert handler 2018-06-07 15:39:40 -07:00
Greg Hysen
5bb7219f4b Camelcase in memCopy 2018-06-07 15:39:40 -07:00
Greg Hysen
f457a56d4a Style updates to contracts 2018-06-07 15:39:40 -07:00
Greg Hysen
12e2bfc794 Fixes after rebasing 2018-06-07 15:39:38 -07:00
Greg Hysen
e4e3676095 Fixed up after rebasing. Contracts build and tests pass 2018-06-07 15:38:48 -07:00
Greg Hysen
8496c1cdd3 Call safeTransferFrom only when there is receiver data present 2018-06-07 15:38:48 -07:00
Greg Hysen
05f1e9e3b8 Resolved edge case in Memcpy where where send would eventually turn "negative" and wrap around. 2018-06-07 15:38:48 -07:00
Greg Hysen
5db15ca54c proxyData -> assetData 2018-06-07 15:38:48 -07:00
Remco Bloemen
63014aeb6b Add tests for word loop iteration 2018-06-07 15:38:48 -07:00
Remco Bloemen
31e21db5b5 Add test for zero-size overlap 2018-06-07 15:38:48 -07:00
Remco Bloemen
7f21872510 Add test cases 2018-06-07 15:38:47 -07:00
Remco Bloemen
27351c9a90 Cleanup test script 2018-06-07 15:38:47 -07:00
Remco Bloemen
76b918d40e Convert Solidity tests to vectors 2018-06-07 15:38:47 -07:00
Remco Bloemen
f5bc0b205c Generate tests from vectors 2018-06-07 15:38:47 -07:00
Greg Hysen
b3c253ea2a Tests for writing bytes to nested bytes 2018-06-07 15:38:47 -07:00
Greg Hysen
842363200b Tons of tests around nested byte arrays and ERC721 receiver 2018-06-07 15:38:42 -07:00
Greg Hysen
9b82e2df58 Foundation for TestLibAssetProxyDecoder 2018-06-07 15:36:18 -07:00
Greg Hysen
3d65341080 Tests for libMem 2018-06-07 15:36:18 -07:00
Fabio Berger
18ed45597a Fix tslint issues 2018-06-07 18:58:51 +02:00
Fabio Berger
73429fc720 merge v2-prototype 2018-06-07 12:27:03 +02:00
fragosti
e0d5b9daf8 Merge branch 'v2-prototype' of https://github.com/0xProject/0x-monorepo into feature/improve-linting 2018-06-06 16:36:11 -07:00
Alex Browne
167a38e27d Add Async suffix to relevant assertions 2018-06-06 12:41:14 -07:00
Alex Browne
d6d7f4e875 Update more things to work with both Geth and Ganache 2018-06-06 12:40:31 -07:00
Alex Browne
98ffe9931d Get LibBytes tests working on both Ganache and Geth 2018-06-06 12:40:30 -07:00
Alex Browne
31c98fc0db Update some tests after rebase 2018-06-06 12:39:43 -07:00
Alex Browne
00bf957b53 Add more transactions to Geth on init. Skip tests that are failing. 2018-06-06 12:39:43 -07:00
Alex Browne
1cc9d9c071 Replace constant.REVERT test assertions with expectRevertOrAlwaysFailingTransaction 2018-06-06 12:39:42 -07:00
Fabio Berger
cb754ee125 move generated contract wrappers from contract_wrappers/generated/ to generated_contract_wrappers in package with no non-generated contract wrappers 2018-06-06 15:39:38 +02:00
fragosti
59cb2132f2 Linter now passes 2018-06-05 11:46:05 -07:00
Fabio Berger
b7b45b69a6 Merge branch 'v2-prototype' into refactor/order-utils/for-v2
* v2-prototype: (33 commits)
  Only show ProviderDisplay in portal
  Improve sol-cov docs
  Remove old parse code
  Refactor order parser and add shared order support to new portal
  Add generate and fill order routes
  Address feedback
  Override ethereumjs-tx version
  Fix missing key
  Update placeholder param ordering
  Change userEtherBalanceInWei to optional so we can know if its loading
  Add loading state to ProviderDisplay
  Tweaks
  Add Placeholder component
  Add StandardIconRow
  Split render into loading and loaaded
  Fix linter errors
  Fix linter errors
  Add ethereum-types to extraFileIncludes
  Introduce ethereum-types package
  Remove merge conflicts from yarn.lock
  ...

# Conflicts:
#	packages/contracts/src/utils/exchange_wrapper.ts
#	packages/contracts/src/utils/match_order_tester.ts
#	packages/contracts/src/utils/types.ts
#	packages/contracts/test/exchange/core.ts
#	packages/contracts/test/exchange/match_orders.ts
#	packages/contracts/test/libraries/lib_bytes.ts
#	packages/sol-cov/package.json
2018-06-01 13:05:17 -07:00