dagger-contracts/contracts/TestProofs.sol

53 lines
1.1 KiB
Solidity
Raw Normal View History

// SPDX-License-Identifier: MIT
pragma solidity ^0.8.0;
import "./Proofs.sol";
// exposes internal functions of Proofs for testing
contract TestProofs is Proofs {
2022-02-09 13:17:23 +00:00
function period(bytes32 id) public view returns (uint256) {
return _period(id);
}
2022-02-09 13:17:23 +00:00
function timeout(bytes32 id) public view returns (uint256) {
return _timeout(id);
}
2022-02-09 13:17:23 +00:00
function end(bytes32 id) public view returns (uint256) {
return _end(id);
}
2022-02-09 13:17:23 +00:00
function missed(bytes32 id) public view returns (uint256) {
return _missed(id);
}
function expectProofs(
bytes32 id,
2022-02-09 13:17:23 +00:00
uint256 _period,
uint256 _timeout,
uint256 _duration
) public {
_expectProofs(id, _period, _timeout, _duration);
}
2022-02-09 13:17:23 +00:00
function isProofRequired(bytes32 id, uint256 blocknumber)
public
view
returns (bool)
{
return _isProofRequired(id, blocknumber);
}
function submitProof(
bytes32 id,
2022-02-09 13:17:23 +00:00
uint256 blocknumber,
bool proof
2022-02-09 13:17:23 +00:00
) public {
_submitProof(id, blocknumber, proof);
}
2022-02-09 13:17:23 +00:00
function markProofAsMissing(bytes32 id, uint256 blocknumber) public {
_markProofAsMissing(id, blocknumber);
}
}