public void GivenMaxNumber_ThirdPosition() { int result = MaximumNumberCheck.findMaximum(10, 20, 40); int maxNumber = 40; Assert.AreEqual(maxNumber, result); }
public void GivenMaxString_WhenAtSecondPoistion_ThenReturnSameStringUsingGenricMethode() { string expected = "Peach"; string maxString = MaximumNumberCheck.findMaximum <string>("Apple", "Peach", " Banana"); Assert.AreEqual(expected, maxString); }
public void GivenMaxNumber_FirstPosition() { int result = MaximumNumberCheck.findMaximum(40, 20, 30); int maxNumber = 40; Assert.AreEqual(maxNumber, result); }
public void GivenMaxIntegerNumber_WhenAtThirdPosition_ThenReturnSameNumberUsingGenricMethode() { int expected = 800; int maxNumber = MaximumNumberCheck.findMaximum <int>(700, 600, 800); Assert.AreEqual(expected, maxNumber); }
public void GivenMaxFloatNumber_WhenAtThirdPosition_ThenReturnSameNumberUsingGenricMethode() { double expected = 70.0; double maxNumber = MaximumNumberCheck.findMaximum <double>(60.0, 70.0, 50.0); Assert.AreEqual(expected, maxNumber); }
/// <summary> /// Given the maximum string second position. /// </summary> public void GivenMaxString_SecondPosition() { string result = MaximumNumberCheck.findMaximum("Apple", "Peach", "Banana"); string maxString = "Peach"; Assert.AreEqual(maxString, result); }
/// <summary> /// Given the maximum float number third position. /// </summary> public void GivenMaxFloatNumber_ThirdPosition() { double result = MaximumNumberCheck.findMaximum(20.2, 33.3, 55.5); double maxNumber = 55.5; Assert.AreEqual(maxNumber, result); }
//Act public void Given_MaxStringAt2ndPosition_WhenChecked_ThenReturn_SameNumber() { string expectedResult = "Carrot"; string result = MaximumNumberCheck.MaximumStringNumber("Apple", "Carrot", "Banana"); //Assert Assert.AreEqual(expectedResult, result); }
//Act public void Given_MaxFloatNumberAt3rdPosition_WhenChecked_ThenReturn_SameNumber() { double expectedResult = 111.44; double result = MaximumNumberCheck.MaximumFloatNumber(44.20, 33.65, 111.44); //Assert Assert.AreEqual(expectedResult, result); }
public void Given_Strings_Max_At_Second_Position_Return_Max(string str1, string str2, string str3) { MaximumNumberCheck MaxString = new MaximumNumberCheck(); string result = MaxString.MaximumStringNumber(str1, str2, str3); string expected = str2; Assert.AreEqual(expected, result); }
public void Given_Float_Max_Number_At_Third_Position_Return_Max(float num1, float num2, float num3) { MaximumNumberCheck MaxFloat = new MaximumNumberCheck(); float result = MaxFloat.MaximumFloatNumber(num1, num2, num3); float expected = num3; Assert.AreEqual(expected, result); }
public void Given_Int_Max_Number_At_Third_Position_Return_Max(int num1, int num2, int num3) { MaximumNumberCheck MaxInt = new MaximumNumberCheck(); int result = MaxInt.MaximumIntegerNumber(num1, num2, num3); int expected = num3; Assert.AreEqual(expected, result); }
//Act public void Given_MaxStringNumberAt2ndPosition_WhenChecked_ThenReturn_SameNumber() { string expectedResult = "44"; string result = MaximumNumberCheck.MaximumStringNumber("33", "44", "22"); //Assert Assert.AreEqual(expectedResult, result); }
//Act public void Given_MaxNumberAt3rdPosition_WhenChecked_ThenReturn_SameNumber() { int expectedResult = 44; int result = MaximumNumberCheck.MaximumIntegerNumber(33, 11, 44); //Assert Assert.AreEqual(expectedResult, result); }
public void GivenStringArray_ShouldReturnMaximumString() { string[] stringArray = { "Apple", "Peach", "Banana", "Cherry" }; string expected = "Peach"; MaximumNumberCheck <string> maximumNumberCheck = new MaximumNumberCheck <string>(stringArray); string result = maximumNumberCheck.MaxMethod(); Assert.AreEqual(expected, result); }
public void GivenFloatArray_ShouldReturnMaximumFloatNumber() { float[] floatArray = { 12.4f, 22.6f, 17.4f, 11.9f }; float expected = 22.6f; MaximumNumberCheck <float> maximumNumberCheck = new MaximumNumberCheck <float>(floatArray); float result = maximumNumberCheck.MaxMethod(); Assert.AreEqual(expected, result); }
public void GivenIntArray_ShouldReturnMaximumNumber() { int[] intArray = { 12, 22, 11, 17 }; int expected = 22; MaximumNumberCheck <int> maximumNumberCheck = new MaximumNumberCheck <int>(intArray); int result = maximumNumberCheck.MaxMethod(); Assert.AreEqual(expected, result); }
public void GivenStringArray_Should_Return_LargestString() { ///Arrange string[] values = { "22", "98", "99", "33" }; MaximumNumberCheck <string> maximumNumber = new MaximumNumberCheck <string>(values); ///Act string max = maximumNumber.MaxMethod(); ///Assert Assert.AreEqual("99", max); }
public void GivenDoubleArray_Should_Return_LargestDouble() { ///Arrange double[] values = { 10.6, 25.9, 8.2, 9.56 }; MaximumNumberCheck <double> maximumNumber = new MaximumNumberCheck <double>(values); ///Act double max = maximumNumber.MaxMethod(); ///Assert Assert.AreEqual(25.9, max); }
public void GivenMaximumNumberAtThirdPosition_ShouldReturn_SameNumber() { ///Arrange int expectedValue = 11; MaximumNumberCheck maximumNumber = new MaximumNumberCheck(); ///Act int actualValue = maximumNumber.MaximumIntegerNumber(5, 9, 11); ///Assert Assert.AreEqual(expectedValue, actualValue); }
public void GivenIntegerArray_Should_Return_LargestInteger() { ///Arrange int[] values = { 3, 6, 7, 10, 4, 8 }; MaximumNumberCheck <int> maximumNumber = new MaximumNumberCheck <int>(values); ///Act int max = maximumNumber.MaxMethod(); ///Assert Assert.AreEqual(10, max); }
public void Max_WhenCalled_ReturnsMaxString(string string1, string string2, string string3, string max) { var result = MaximumNumberCheck.Max(string1, string2, string3); Assert.That(result, Is.EqualTo(max)); }
public void Max_WhenCalled_ReturnsMaximumInterger(int integer1, int integer2, int integer3, int max) { var result = MaximumNumberCheck.Max(integer1, integer2, integer3); Assert.That(result, Is.EqualTo(max)); }
public void Max_WhenCalled_ReturnsMaximumdouble(double double1, double double2, double double3, double max) { var result = MaximumNumberCheck.Max(double1, double2, double3); Assert.That(result, Is.EqualTo(max)); }