Skip to content

Commit

Permalink
Added mock bond manager to deploy config (#87)
Browse files Browse the repository at this point in the history
  • Loading branch information
smartcontracts authored Dec 1, 2020
1 parent f24339f commit 5a57bb0
Show file tree
Hide file tree
Showing 2 changed files with 80 additions and 0 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1,77 @@
// SPDX-License-Identifier: MIT
pragma solidity ^0.7.0;

/* Interface Imports */
import { iOVM_BondManager } from "../../iOVM/verification/iOVM_BondManager.sol";

/**
* @title mockOVM_BondManager
*/
contract mockOVM_BondManager is iOVM_BondManager {
function recordGasSpent(
bytes32 _preStateRoot,
address _who,
uint256 _gasSpent
)
override
public
{}

function finalize(
bytes32 _preStateRoot,
address _publisher,
uint256 _timestamp
)
override
public
{}

function deposit()
override
public
{}

function startWithdrawal()
override
public
{}

function finalizeWithdrawal()
override
public
{}

function claim(
bytes32 _preStateRoot
)
override
public
{}

function isCollateralized(
address _who
)
override
public
view
returns (
bool
)
{
return true;
}

function getGasSpent(
bytes32 _preStateRoot,
address _who
)
override
public
view
returns (
uint256
)
{
return 0;
}
}
3 changes: 3 additions & 0 deletions packages/contracts/src/contract-deployment/config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -155,5 +155,8 @@ export const makeContractDeployConfig = async (
mockOVM_ECDSAContractAccount: {
factory: getContractFactory('mockOVM_ECDSAContractAccount'),
},
OVM_BondManager: {
factory: getContractFactory('mockOVM_BondManager'),
},
}
}

0 comments on commit 5a57bb0

Please sign in to comment.