@@ -321,18 +321,6 @@ contract("ManualApprovalTransferManager", accounts => {
321321 assert . equal ( ( await I_SecurityToken . balanceOf ( account_investor1 ) ) . toNumber ( ) , web3 . utils . toWei ( "5" , "ether" ) ) ;
322322 } ) ;
323323
324- it ( "Should fail to add a manual approval because invalid _from address" , async ( ) => {
325- await catchRevert (
326- I_ManualApprovalTransferManager . addManualApproval (
327- "" ,
328- account_investor4 ,
329- web3 . utils . toWei ( "2" , "ether" ) ,
330- latestTime ( ) + duration . days ( 1 ) ,
331- { from : token_owner }
332- )
333- ) ;
334- } ) ;
335-
336324 it ( "Should fail to add a manual approval because invalid _to address" , async ( ) => {
337325 await catchRevert (
338326 I_ManualApprovalTransferManager . addManualApproval (
@@ -367,6 +355,16 @@ contract("ManualApprovalTransferManager", accounts => {
367355 ) ;
368356 } ) ;
369357
358+ it ( "Add a manual approval for a 5th investor from issuance" , async ( ) => {
359+ await I_ManualApprovalTransferManager . addManualApproval (
360+ "" ,
361+ account_investor5 ,
362+ web3 . utils . toWei ( "2" , "ether" ) ,
363+ latestTime ( ) + duration . days ( 1 ) ,
364+ { from : token_owner }
365+ ) ;
366+ } ) ;
367+
370368 it ( "Should fail to add a manual approval because allowance is laready exists" , async ( ) => {
371369 await catchRevert (
372370 I_ManualApprovalTransferManager . addManualApproval (
@@ -379,10 +377,6 @@ contract("ManualApprovalTransferManager", accounts => {
379377 ) ;
380378 } ) ;
381379
382- it ( "Should fail to revoke manual approval because invalid _from address" , async ( ) => {
383- await catchRevert ( I_ManualApprovalTransferManager . revokeManualApproval ( "" , account_investor4 , { from : token_owner } ) ) ;
384- } ) ;
385-
386380 it ( "Should fail to revoke manual approval because invalid _to address" , async ( ) => {
387381 await catchRevert ( I_ManualApprovalTransferManager . revokeManualApproval ( account_investor1 , "" , { from : token_owner } ) ) ;
388382 } ) ;
@@ -409,6 +403,15 @@ contract("ManualApprovalTransferManager", accounts => {
409403 assert . equal ( ( await I_SecurityToken . balanceOf ( account_investor4 ) ) . toNumber ( ) , web3 . utils . toWei ( "1" , "ether" ) ) ;
410404 } ) ;
411405
406+ it ( "Approval fails with wrong from to address" , async ( ) => {
407+ await catchRevert ( I_SecurityToken . transfer ( account_investor5 , web3 . utils . toWei ( "1" , "ether" ) , { from : account_investor1 } ) ) ;
408+ } ) ;
409+
410+ it ( "Use 100% of issuance approval" , async ( ) => {
411+ await I_SecurityToken . mint ( account_investor5 , web3 . utils . toWei ( "2" , "ether" ) , { from : token_owner } ) ;
412+ assert . equal ( ( await I_SecurityToken . balanceOf ( account_investor5 ) ) . toNumber ( ) , web3 . utils . toWei ( "2" , "ether" ) ) ;
413+ } ) ;
414+
412415 it ( "Check verifyTransfer without actually transferring" , async ( ) => {
413416 let verified = await I_SecurityToken . verifyTransfer . call (
414417 account_investor1 ,
@@ -439,14 +442,6 @@ contract("ManualApprovalTransferManager", accounts => {
439442 await I_SecurityToken . transfer ( account_investor2 , web3 . utils . toWei ( "1" , "ether" ) , { from : account_investor1 } ) ;
440443 } ) ;
441444
442- it ( "Should fail to add a manual block because invalid _from address" , async ( ) => {
443- await catchRevert (
444- I_ManualApprovalTransferManager . addManualBlocking ( "" , account_investor2 , latestTime ( ) + duration . days ( 1 ) , {
445- from : token_owner
446- } )
447- ) ;
448- } ) ;
449-
450445 it ( "Should fail to add a manual block because invalid _to address" , async ( ) => {
451446 await catchRevert (
452447 I_ManualApprovalTransferManager . addManualBlocking ( account_investor1 , "" , latestTime ( ) + duration . days ( 1 ) , {
@@ -477,10 +472,6 @@ contract("ManualApprovalTransferManager", accounts => {
477472 await catchRevert ( I_SecurityToken . transfer ( account_investor2 , web3 . utils . toWei ( "1" , "ether" ) , { from : account_investor1 } ) ) ;
478473 } ) ;
479474
480- it ( "Should fail to revoke manual block because invalid _from address" , async ( ) => {
481- await catchRevert ( I_ManualApprovalTransferManager . revokeManualBlocking ( "0x0" , account_investor2 , { from : token_owner } ) ) ;
482- } ) ;
483-
484475 it ( "Should fail to revoke manual block because invalid _to address" , async ( ) => {
485476 await catchRevert ( I_ManualApprovalTransferManager . revokeManualBlocking ( account_investor1 , "0x0" , { from : token_owner } ) ) ;
486477 } ) ;
0 commit comments