Skip to content

Commit

Permalink
test(protocol): TaikoL1 Committing + Proposing Integration Tests (#7310)
Browse files Browse the repository at this point in the history
* commitBlock() + proposeBlock() integration tests for TaikoL1

* whitelisting, getProposedBlock, isCommitValid tests for TaikoL1

* test fixes + husky pre commit restoration

* chore(docs): auto commit solidity docs

* lint

* code cleanup

* Update packages/protocol/test/L1/TaikoL1.test.ts

Co-authored-by: David <david@taiko.xyz>

Co-authored-by: cyberhorsey <cyberhorsey@users.noreply.github.com>
Co-authored-by: David <david@taiko.xyz>
  • Loading branch information
3 people committed Jan 5, 2023
1 parent a091bc0 commit cc50dfd
Show file tree
Hide file tree
Showing 4 changed files with 379 additions and 55 deletions.
4 changes: 2 additions & 2 deletions packages/protocol/contracts/test/L1/TestTaikoL1.sol
Original file line number Diff line number Diff line change
Expand Up @@ -26,9 +26,9 @@ contract TestTaikoL1 is TaikoL1, IProofVerifier {
// the 'the maximum value of the multiplier' close to 20.0
config.zkProofsPerBlock = 1;
config.maxVerificationsPerTx = 2;
config.commitConfirmations = 0;
config.commitConfirmations = 1;
config.maxProofsPerForkChoice = 5;
config.blockMaxGasLimit = 5000000; // TODO
config.blockMaxGasLimit = 30000000; // TODO
config.maxTransactionsPerBlock = 20; // TODO
config.maxBytesPerTxList = 10240; // TODO
config.minTxGasLimit = 21000; // TODO
Expand Down
45 changes: 0 additions & 45 deletions packages/protocol/docs/L1/TaikoL1.md
Original file line number Diff line number Diff line change
Expand Up @@ -101,51 +101,6 @@ Verify up to N blocks.
| --------- | ------- | ------------------------------- |
| maxBlocks | uint256 | Max number of blocks to verify. |

### enableWhitelisting

```solidity
function enableWhitelisting(bool whitelistProposers, bool whitelistProvers) public
```

Enable or disable proposer and prover whitelisting

#### Parameters

| Name | Type | Description |
| ------------------ | ---- | ------------------------------------- |
| whitelistProposers | bool | True to enable proposer whitelisting. |
| whitelistProvers | bool | True to enable prover whitelisting. |

### whitelistProposer

```solidity
function whitelistProposer(address proposer, bool whitelisted) public
```

Add or remove a proposer from the whitelist.

#### Parameters

| Name | Type | Description |
| ----------- | ------- | ------------------------------------ |
| proposer | address | The proposer to be added or removed. |
| whitelisted | bool | True to add; remove otherwise. |

### whitelistProver

```solidity
function whitelistProver(address prover, bool whitelisted) public
```

Add or remove a prover from the whitelist.

#### Parameters

| Name | Type | Description |
| ----------- | ------- | ---------------------------------- |
| prover | address | The prover to be added or removed. |
| whitelisted | bool | True to add; remove otherwise. |

### halt

```solidity
Expand Down
Loading

0 comments on commit cc50dfd

Please sign in to comment.