public void TestOnInputValueGreaterThanMaximalValueShouldReturn100()
 {
     var laptopBattery = new LaptopBattery();
     laptopBattery.Charge(10000);
     var exceptedPercentage = 100;
     Assert.AreEqual(exceptedPercentage, laptopBattery.Percentage);
 }
 public void TestOnNegativeInputValueShouldReturnZero()
 {
     var laptopBattery = new LaptopBattery();
     laptopBattery.Charge(-1000);
     var exceptedPercentage = 0;
     Assert.AreEqual(exceptedPercentage, laptopBattery.Percentage);
 }
 public void Add50PercentsShouldReturn100()
 {
     var laptopBattery = new LaptopBattery();
     laptopBattery.Charge(50);
     var exceptedPercentage = 100;
     Assert.AreEqual(exceptedPercentage, laptopBattery.Percentage);
 }
 public void Subtract50PercentsShouldReturnZero()
 {
     var laptopBattery = new LaptopBattery();
     laptopBattery.Charge(-50);
     var exceptedPercentage = 0;
     Assert.AreEqual(exceptedPercentage, laptopBattery.Percentage);
 }
 public void SetInvalidNonNegativePercentageViaPropertyShouldThrowException()
 {
     var laptopBattery = new LaptopBattery();
     laptopBattery.Percentage = 150;
 }
 public void CreateBatteryInitiallyShouldReturn50Percents()
 {
     var laptopBattery = new LaptopBattery();
     var exceptedPercentage = 50;
     Assert.AreEqual(exceptedPercentage, laptopBattery.Percentage);
 }