1990 Commits

Author SHA1 Message Date
Alex Towle
3a1fc9ee5f @0x:contracts-integrations Fixed package after rebase 2019-10-22 13:15:01 -07:00
mzhu25
1237c7d479
Merge pull request #2277 from 0xProject/fix/3.0/rmeove-staking-fallback
Remove payable fallback from Staking.sol
2019-10-22 12:46:13 -07:00
Greg Hysen
c44e16a88f Removed assertion that protocol fee != 0 from staking contract. 2019-10-22 12:42:04 -07:00
Greg Hysz
06c180475e
Merge pull request #2276 from 0xProject/cleanup/staking/finalizationDataStructures
Refactored finalization state.
2019-10-22 12:37:50 -07:00
Michael Zhu
74a2c3a199 Remove payable fallback from Staking.sol 2019-10-22 12:15:07 -07:00
Greg Hysen
9ac715f99d Protocol fee amount is not enforced by staking contract 2019-10-22 12:10:34 -07:00
Greg Hysen
22e39f782f Some (more) readability improvements and minor optimizations to staking finalization. 2019-10-22 12:09:18 -07:00
Alex Towle
718407ba6f @0x:contracts-integrations Switched to object destructuring in the function assertion unit test 2019-10-22 12:07:50 -07:00
Alex Towle
e603a81a46 @0x:contracts-integrations Simplified the tests 2019-10-22 12:07:50 -07:00
Alex Towle
03e35846fb @0x:contracts-integrations Removed the Cache 2019-10-22 12:07:50 -07:00
Alex Towle
c87364f86b @0x:contracts-integrations Addressed more review feedback 2019-10-22 12:07:50 -07:00
Alex Towle
a794a33551 @0x:contracts-integrations Addressed review comments 2019-10-22 12:06:38 -07:00
Alex Towle
494b437f1a @0x:contracts-integrations Renamed some functions in Address Manager 2019-10-22 12:04:47 -07:00
Alex Towle
92b80fc436 @0x:contracts-integrations Improved the caches 2019-10-22 12:04:47 -07:00
Alex Towle
d66101cd9d @0x:contracts-integrations Added unit tests for FunctionAssertion 2019-10-22 12:04:47 -07:00
Alex Towle
89ae04803f @0x:contract-integrations Added the integrations package to CI 2019-10-22 12:01:54 -07:00
Alex Towle
be95bce4cd @0x:contract-integrations Move caches to a new file 2019-10-22 12:01:30 -07:00
Alex Towle
01aee08c02 @0x:contracts-integrations Wrote a simple integration test and AddressManager 2019-10-22 12:01:30 -07:00
Alex Towle
6cba9fd77f @0x/contracts-integrations Created the FunctionAssertion class and examples 2019-10-22 11:59:17 -07:00
mzhu25
673d45361f
Merge pull request #2273 from 0xProject/refactor/integrations/coordinator-tests
Coordinator test refactor [1/2] + actor mixin pattern
2019-10-22 11:37:02 -07:00
Greg Hysen
d91a7fc663 Some readability improvements and minor optimizations to staking finalization. 2019-10-22 11:02:25 -07:00
Greg Hysen
ce8fd44234 Removed lingering references to stale terminology ("active pools") 2019-10-22 11:02:25 -07:00
Greg Hysen
6617ad9531 Refactored finalization state.
1. Removes state variables:
   - totalWeightedStakeThisEpoch
   - totalFeesCollectedThisEpoch
   - numActivePoolsThisEpoch

2. No longer indexes by epoch % 2

3. Renamed event StakingPoolActivated → StakingPoolEarnedRewards.

4. Renamed structs:
   - ActivePool → PoolStats. This holds stats for a pool that earned rewards.
   - UnfinalizedState → AggregatedStats. This aggregates stats from the former struct.
2019-10-22 11:02:25 -07:00
Amir Bandeali
e7dc7167d0 Sync delegatedStakeToPoolByOwner whenever _withdrawAndSyncDelegatorRewards is called 2019-10-22 09:38:18 -07:00
Amir Bandeali
359b804001 Add test for withdrawing rewards before epoch is finalized 2019-10-21 22:27:06 -07:00
Amir Bandeali
44dac2cd80 Fix tests that assume touching stake will finalize pool 2019-10-21 22:27:06 -07:00
Amir Bandeali
a66ea2bf74 Assert that pool has been finalized in _withdrawAndSyncDelegatorRewards rather than calling finalizePool 2019-10-21 22:27:06 -07:00
Amir Bandeali
a362e9d2d8 Use safeMath where possible 2019-10-21 22:27:06 -07:00
Amir Bandeali
1885957bd3 Update tests to start at epoch 1 2019-10-21 22:27:06 -07:00
Amir Bandeali
1a409c3731 Initialize currentEpoch at 1 instead of 0 2019-10-21 22:27:06 -07:00
Amir Bandeali
7b7c64fc6a Add assertion function that checks if pool was finalized last epoch 2019-10-21 22:27:06 -07:00
Michael Zhu
102fcd3fb8 export actor classes 2019-10-21 11:17:53 -07:00
Michael Zhu
566e05aea4 typo 2019-10-21 11:17:53 -07:00
Michael Zhu
f014370531 document mixin constructor params 2019-10-21 11:17:53 -07:00
Michael Zhu
dfbbe9daa2 address comments 2019-10-21 11:17:53 -07:00
Michael Zhu
6b653fb00d prettier gdi 2019-10-21 11:17:53 -07:00
Michael Zhu
21cf2319d5 rename some stuff 2019-10-21 11:17:53 -07:00
Michael Zhu
4210477e71 Introduce actor mixin pattern 2019-10-21 11:17:53 -07:00
Michael Zhu
93b02e93b9 juggling some files around 2019-10-21 11:16:14 -07:00
Michael Zhu
f4cb8cfb7e Support arbitrary # of tokens in DeploymentManager 2019-10-21 11:16:14 -07:00
Xianny
ce9f051d42
Create @0x/contracts-tests (#2261)
* Create @0x/contracts-tests

* Move tests from @0x/contracts-dev-utils
2019-10-21 10:23:46 -07:00
Amir Bandeali
083216a0c6
Merge pull request #2271 from 0xProject/feat/3.0/zero-ex-governor
Rename AssetProxyOwner to ZeroExGovernor
2019-10-19 17:05:07 -07:00
mzhu25
59a38a8db0
Merge pull request #2269 from 0xProject/refactor/balance-stores
BalanceStore++
2019-10-18 09:01:33 -07:00
Lawrence Forman
d0884dcb4d
Merge pull request #2267 from 0xProject/feat/3.0/staking/MixinStake-unit-tests
Create MixinStake unit tests
2019-10-18 11:41:18 -04:00
Lawrence Forman
c7ca625408 @0x/contracts-staking: Fix MixinStake unit tests typo. 2019-10-18 10:45:07 -04:00
Lawrence Forman
e46f51339a @0x/contracts-staking: Address review comments. 2019-10-18 10:42:47 -04:00
Michael Zhu
b45ec47eee address comments 2019-10-17 19:53:43 -07:00
Amir Bandeali
c50cbd7a75 Rename AssetProxyOwner to ZeroExGovernor throughout all contracts packages 2019-10-17 17:41:54 -07:00
Amir Bandeali
5ddc35fdf2 Rename AssetProxyOwner to ZeroExGovernor 2019-10-17 17:41:54 -07:00
Amir Bandeali
caf6329bb3 Merge branch '3.0' into feat/3.0/testnet-migrations 2019-10-17 17:13:12 -07:00