This repository has been archived by the owner on Mar 3, 2022. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 10
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* Snapshot facet with tests * Removed commented code * Add ownerOrOperator modifier for access control * Added currentEpoch methods to staking for compatibility. * Removed commented code. Added participants modifier for snapshots. * Recompiled and generated bindings. * Restricted facet for diamond maintenance * Added admin functions to interface * Added missing majorFine()/minorFine() * Adding migration contracts/facets * Moved event definitions * ETHDKG migrator + test * Fixed loop index for members * Switch from a manual call() to a cast * Added snapshot failure test for bad signature * Added test for migration of snapshot * Added staking test case * Create constant for minimum stake. Added testing for immediately adding/removing validator * Turned off test tracing and generated bindings * Put the owner only requirement back * Regenerated bindings * Renamed overloaded function deposit() to depositFor() * Minor style updates to match recommendations * Feature complete ETHDKG replacement with diamond pattern * Complete unit tests * Put missing access controls back * Finished splitting ETHDKG * Added restart of ETHDKG if final completion detects issue * Made validator queueing consistently require staking. Restored snapshot rewards. * Phase length admin exposed * Consolidated EthDKG constants into Library. Updated abicoder to v2. * Removed commented code. * Renamed utility token * Brought over TODOs from Chris
- Loading branch information
Showing
33 changed files
with
3,470 additions
and
744 deletions.
There are no files selected for viewing
Large diffs are not rendered by default.
Oops, something went wrong.
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
// SPDX-License-Identifier: MIT-open-group | ||
pragma solidity >=0.7.4; | ||
|
||
import "ds-test/test.sol"; | ||
|
||
import "./Setup.t.sol"; | ||
|
||
|
||
contract EthDKG is Constants, DSTest, Setup { | ||
|
||
address me = address(this); | ||
|
||
function testGetDefaultPhaseLength() public { | ||
ethdkg.initializeEthDKG(registry); | ||
assertEq(ethdkg.getPhaseLength(), 40); | ||
} | ||
|
||
function testSetPhaseLength() public { | ||
ethdkg.initializeEthDKG(registry); | ||
|
||
ethdkg.updatePhaseLength(4); | ||
assertEq(ethdkg.getPhaseLength(), 4); | ||
} | ||
|
||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.