* Added basic Escrow * PullPayment now uses an Escrow, removing all trust from the contract * Abstracted the Escrow tests to a behaviour * Added ConditionalEscrow * Added RefundableEscrow. * RefundableCrowdsale now uses a RefundEscrow, removed RefundVault. * Renaming after code review. * Added log test helper. * Now allowing empty deposits and withdrawals. * Style fixes. * Minor review comments. * Add Deposited and Withdrawn events, removed Refunded * The base Escrow is now Ownable, users of it (owners) must provide methods to access it.
19 lines
415 B
Solidity
19 lines
415 B
Solidity
pragma solidity ^0.4.24;
|
|
|
|
|
|
import "../payment/ConditionalEscrow.sol";
|
|
|
|
|
|
// mock class using ConditionalEscrow
|
|
contract ConditionalEscrowMock is ConditionalEscrow {
|
|
mapping(address => bool) public allowed;
|
|
|
|
function setAllowed(address _payee, bool _allowed) public {
|
|
allowed[_payee] = _allowed;
|
|
}
|
|
|
|
function withdrawalAllowed(address _payee) public view returns (bool) {
|
|
return allowed[_payee];
|
|
}
|
|
}
|