Add bounty test to test against checkInvarient

pull/35/head
Makoto Inoue 8 years ago
parent 441e85d823
commit b5469310a1
  1. 4
      contracts/bounties/SimpleTokenBounty.sol
  2. 14
      test/Bounty.js

@ -23,6 +23,10 @@ contract SimpleTokenBounty is PullPayment {
return target; return target;
} }
function checkInvarient() returns(bool){
return true;
}
function claim(SimpleToken target) { function claim(SimpleToken target) {
address researcher = researchers[target]; address researcher = researchers[target];
if (researcher == 0) throw; if (researcher == 0) throw;

@ -0,0 +1,14 @@
contract('Bounty', function(accounts) {
it.only("create target", function(done){
var bounty = Bounty.deployed();
bounty.createTarget().
then(function() {
return bounty.checkInvarient.call()
}).
then(function(result) {
assert.isTrue(result);
}).
then(done);
})
});
Loading…
Cancel
Save