DistributeDividends() public method

public DistributeDividends ( Amount amount ) : void
amount Amount
return void
Example #1
0
 public void Should_Be_Able_To_Calculate_Participation()
 {
     Holding holding = new Holding();
     holding.Add(new Investment(new Investor(new Name("quarter"), new GringottsDate(DateTime.Now), new Amount(1500)), null, new Amount(250)));
     holding.Add(new Investment(new Investor(new Name("threeFourths"), new GringottsDate(DateTime.Now), new Amount(1000)), null, new Amount(750)));
     holding.DistributeDividends(new Amount(1000));
 }
Example #2
0
 public void Should_Be_Able_To_Distribute_Dividends_Fairly()
 {
     Amount profit = new Amount(1000);
     Holding holding = new Holding();
     holding.Add(new Investment(new Investor(new Name("quarter"), new GringottsDate(DateTime.Now), new Amount(1500)), null, new Amount(250)));
     holding.Add(new Investment(new Investor(new Name("threeFourths"), new GringottsDate(DateTime.Now), new Amount(1000)), null, new Amount(750)));
     holding.DistributeDividends(profit);
 }