public void TestWeightTest_OverSizePackageInput() { //arrange var categorisePackage = new CategorisePackage(); double costExpected = -1; int weight = 30; //act double cost = categorisePackage.TestWeight(weight); //assert Assert.AreEqual(costExpected, cost); }
public void TestBreadthTest_OversizePackageInput() { //arrange var categorisePackage = new CategorisePackage(); double costExpected = -1; int breadth = 800; //act double cost = categorisePackage.TestBreadth(breadth); //assert Assert.AreEqual(costExpected, cost); }
public void TestHeightTest_LargePackageInput() { //arrange var categorisePackage = new CategorisePackage(); double costExpected = 8.5; int height = 250; //act double cost = categorisePackage.TestHeight(height); //assert Assert.AreEqual(costExpected, cost); }
public void TestLengthTest_OverSizePackageInput() { //arrange var categorisePackage = new CategorisePackage(); double costExpected = -1; int length = 500; //act double cost = categorisePackage.TestLength(length); //assert Assert.AreEqual(costExpected, cost); }
public void OptimisePackage_EqualInputs() { //arrange var userPackageOptimised = new UserPackage(); var userPackage = new UserPackage(); var categorisePackage = new CategorisePackage(); userPackage.Length = 400; userPackage.Breadth = 400; userPackage.Height = 400; var expectedLength = 400; var expectedBreadth = 400; var expectedHeight = 400; //act categorisePackage.OptimiseUserPackageOrientation(userPackageOptimised, userPackage); //assert Assert.AreEqual(expectedLength, userPackageOptimised.Length); Assert.AreEqual(expectedBreadth, userPackageOptimised.Breadth); Assert.AreEqual(expectedHeight, userPackageOptimised.Height); }