@@ -34,13 +34,19 @@ contract('IncreasingPriceCrowdsale', function ([_, investor, wallet, purchaser])
34
34
this . token = await SimpleToken . new ( ) ;
35
35
} ) ;
36
36
37
- it ( 'rejects a final rate larger than the initial rate' , async function ( ) {
37
+ it ( 'reverts with a final rate larger than the initial rate' , async function ( ) {
38
38
await shouldFail . reverting ( IncreasingPriceCrowdsaleImpl . new (
39
39
this . startTime , this . closingTime , wallet , this . token . address , initialRate , initialRate . plus ( 1 )
40
40
) ) ;
41
41
} ) ;
42
42
43
- it ( 'rejects a final rate of zero' , async function ( ) {
43
+ it ( 'reverts with a final equal to the initial rate' , async function ( ) {
44
+ await shouldFail . reverting ( IncreasingPriceCrowdsaleImpl . new (
45
+ this . startTime , this . closingTime , wallet , this . token . address , initialRate , initialRate
46
+ ) ) ;
47
+ } ) ;
48
+
49
+ it ( 'reverts with a final rate of zero' , async function ( ) {
44
50
await shouldFail . reverting ( IncreasingPriceCrowdsaleImpl . new (
45
51
this . startTime , this . closingTime , wallet , this . token . address , initialRate , 0
46
52
) ) ;
@@ -59,6 +65,10 @@ contract('IncreasingPriceCrowdsale', function ([_, investor, wallet, purchaser])
59
65
( await this . crowdsale . finalRate ( ) ) . should . be . bignumber . equal ( finalRate ) ;
60
66
} ) ;
61
67
68
+ it ( 'reverts when the base Crowdsale\'s rate function is called' , async function ( ) {
69
+ await shouldFail . reverting ( this . crowdsale . rate ( ) ) ;
70
+ } ) ;
71
+
62
72
it ( 'returns a rate of 0 before the crowdsale starts' , async function ( ) {
63
73
( await this . crowdsale . getCurrentRate ( ) ) . should . be . bignumber . equal ( 0 ) ;
64
74
} ) ;
0 commit comments