Greg Hysen
aa833ef074
Typos in LibBytes tests
2018-08-29 13:26:46 -07:00
Greg Hysen
5f1c9cfee5
Reverted syntax used by readBytes4 in AssetProxyOwner to be compatible with Solidity v0.4.10
2018-08-29 13:15:40 -07:00
Greg Hysen
62b93cf2eb
More tests for LibBytes
2018-08-29 13:14:51 -07:00
Greg Hysen
8c803ab232
Updated comments for ERC20 proxy to clarify how we load the token address from calldata (3.18 from audit)
2018-08-29 12:25:06 -07:00
Greg Hysen
1c3b2b7141
Updated readBytes4 to match spec + added unit tests. These are 3.5/3.6 from audit
2018-08-29 11:39:52 -07:00
Amir Bandeali
f225f9e7c8
Making rounding consistent in calculateFillResults
2018-08-28 13:25:05 -07:00
Amir Bandeali
14fdb71a71
safeGetPartialAmount ( #1035 )
...
* Added Test "Should transfer correct amounts when left order is fully filled and values pass isRoundingErrorCeil but fail isRoundingErrorFloor"
* Added RoundingError exception to reference function for getPartialAmount
* Added RoundingError exception to reference function for getPartialAmount
* Added isRoundingErrorCeil to getPartialAmountCeil reference funtion
* Computed new values for "Should give right maker a better buy price when correct price is not integral" that does not have a rounding error
* Almost all tests for match orders are passing after adding isRoundingErrorCeil check
* WIP commit: Added rounding error checks to getPartialAmount
* WIP commit: Added rounding error checks to getPartialAmount
* Use safe versions of getPartialAmount
* Update Exchange internals tests
* Run linter
* Found new values for "Should transfer correct amounts when right order fill amount deviates from amount derived by `Exchange.fillOrder`"
* Fixed merge conflicts
* Run all tests
* Cleaned up some comments on match Orders tests
* Fix tests for geth
2018-08-28 13:00:49 -07:00
Alex Browne
2eab0e30b7
fix(contracts): Catch cases where the actual error differs from the expected error ( #1032 )
...
* Catch cases where the actual error differs from the expected error
* Add tests for testWithReferenceFuncAsync
* Small style and comment fixes
2018-08-27 16:07:38 -07:00
Amir Bandeali
6a99bfa68e
Add clarifying comments
2018-08-27 12:01:58 -07:00
Amir Bandeali
f60adbdd72
Remove redundant mstores from fillOrderNoThrow
2018-08-27 11:54:20 -07:00
Alex Browne
ff4f86f1d6
fix(contracts): Use correct error message for division by zero
2018-08-27 11:19:25 -07:00
Fabio Berger
00a4fa5f7c
Publish
...
- 0x.js@1.0.1-rc.6
- @0xproject/abi-gen@1.0.7
- @0xproject/assert@1.0.7
- @0xproject/base-contract@2.0.1
- @0xproject/connect@2.0.0-rc.2
- @0xproject/contract-wrappers@1.0.1-rc.5
- contracts@2.1.42
- @0xproject/dev-utils@1.0.6
- @0xproject/fill-scenarios@1.0.1-rc.5
- @0xproject/forwarder-helper@1.0.1-rc.2
- @0xproject/json-schemas@1.0.1-rc.6
- @0xproject/metacoin@0.0.17
- @0xproject/migrations@1.0.6
- @0xproject/monorepo-scripts@1.0.7
- @0xproject/order-utils@1.0.1-rc.6
- @0xproject/order-watcher@1.0.1-rc.5
- @0xproject/react-docs@1.0.7
- @0xproject/react-shared@1.0.8
- @0xproject/sol-compiler@1.1.1
- @0xproject/sol-cov@2.1.1
- @0xproject/sol-resolver@1.0.7
- @0xproject/sra-report@1.0.7
- @0xproject/sra-spec@1.0.1-rc.6
- @0xproject/subproviders@2.0.1
- @0xproject/testnet-faucets@1.0.43
- @0xproject/types@1.0.1-rc.6
- @0xproject/utils@1.0.7
- @0xproject/web3-wrapper@2.0.1
- @0xproject/website@0.0.46
2018-08-27 14:48:24 +01:00
Amir Bandeali
00e7c70b4d
Merge pull request #986 from 0xProject/feature/contracts/assertions
...
Add more assertions to assertValidFill
2018-08-24 20:03:28 -07:00
Remco Bloemen
d652deea23
Merge branch 'fix/contracts/robustMatching' of github.com:0xProject/0x.js into fix/contracts/robustMatching
2018-08-24 18:54:15 -07:00
Greg Hysen
878db3b849
Added comments to order matching
2018-08-24 18:48:29 -07:00
Greg Hysen
ec2e726be0
Rephrased some of the math in MixinMatchOrders to improve readability
2018-08-24 18:20:26 -07:00
Greg Hysen
287830d6e0
Run all tests
2018-08-24 18:20:26 -07:00
Greg Hysen
c7a7ae7e18
Give right maker better price when correct value is not integral
2018-08-24 18:20:26 -07:00
Greg Hysen
1c7ba6a315
Extract only fill
event logs
2018-08-24 18:20:26 -07:00
Greg Hysen
0a6f107243
Added temporary @todo to MixinMatchOrders
2018-08-24 18:20:25 -07:00
Greg Hysen
a93f95c55e
Wording in MixinMatchOrders
2018-08-24 18:20:25 -07:00
Greg Hysen
6833e243b7
Addressed linter errors in match order tesster
2018-08-24 18:20:25 -07:00
Greg Hysen
81dc893d1d
Removed a redundant comment from matchOrders
2018-08-24 18:20:25 -07:00
Greg Hysen
f8e565bc06
Tests for matchOrders edge cases
2018-08-24 18:20:25 -07:00
Greg Hysen
ba15fb6a06
Swapped direction of expect
values to match output in failure cases
2018-08-24 18:20:25 -07:00
Greg Hysen
1e6b83719a
Renaming verify -> assert in order matching
2018-08-24 18:20:25 -07:00
Greg Hysen
9fcb2dda73
Fixed a function comment
2018-08-24 18:20:25 -07:00
Greg Hysen
9a5ec8d030
Added function signature comments
2018-08-24 18:20:25 -07:00
Greg Hysen
ac872e5181
Added expect
messages for checking left/right order states
2018-08-24 18:20:25 -07:00
Greg Hysen
70863cca08
Ran prettier and linter
2018-08-24 18:20:25 -07:00
Greg Hysen
5a1dce15be
Updated all existing match order tests to use new format
2018-08-24 18:19:43 -07:00
Greg Hysen
d291256158
Passes comprehensive test
2018-08-24 18:18:30 -07:00
Greg Hysen
8c706ac639
Verify logs
2018-08-24 18:18:30 -07:00
Greg Hysen
f697814849
First balance test with intentional values
2018-08-24 18:18:30 -07:00
Greg Hysen
ca5c9e77c0
Ironing out the new set of test cases for order matchubng
2018-08-24 18:17:27 -07:00
Greg Hysen
a32b201afe
Rounding for fees in match orders addressed, plus example
2018-08-24 18:17:27 -07:00
Greg Hysen
0ecdf1e213
All existing tests pass.
2018-08-24 18:17:26 -07:00
Greg Hysen
057891b342
Added fees to matchOrders (previously in calculateFillResults
2018-08-24 18:17:26 -07:00
Greg Hysen
407f63ef20
Removed calculateFillResults from matchOrders workflow. Eliminates compounded rounding errors.
2018-08-24 18:17:26 -07:00
Amir Bandeali
c8500cab10
Fix build
2018-08-24 17:30:56 -07:00
Amir Bandeali
c28c3db63f
Only use one nonReentrant modifier, remove modifier from fillOrderNoThrow variations
2018-08-24 17:30:56 -07:00
Amir Bandeali
a09ee90739
Add tests for matchOrders
2018-08-24 17:30:56 -07:00
Amir Bandeali
7d5a23969d
Add reentrancy tests for fillOrder and wrapper functions
2018-08-24 17:30:56 -07:00
Amir Bandeali
56c3c29feb
Update ReentrantERC20Token with new functions and check that revert is occuring for correct reason
2018-08-24 17:30:56 -07:00
Amir Bandeali
c75212bef0
Add nonReentrant modifiers on functions that use getCurrentContextAddress only, add lockMutex modifier on functions that make external calls
2018-08-24 17:30:56 -07:00
Amir Bandeali
6d0dedc62c
Split modifiers into check only and check, lock, unlock
2018-08-24 17:30:56 -07:00
Amir Bandeali
cf12daea2f
Add ReentrantToken
2018-08-24 17:30:56 -07:00
Amir Bandeali
6f88e9bdbd
Add internal fill functions, add reentrancy guard to public functions that make external calls
2018-08-24 17:30:56 -07:00
Amir Bandeali
d8cb56caa3
Add ReentrancyGuard contract
2018-08-24 17:30:56 -07:00
Amir Bandeali
044415e23d
Remove redundant sload from getCurrentContextAddress
2018-08-24 17:30:56 -07:00