Beispiel #1
0
 public void FirstHalf(string str, string expected)
 {
     //arrange
     Strings obj = new Strings();
     //act
     string actual = obj.FirstHalf(str);
     //assert
     Assert.AreEqual(expected, actual);
 }
Beispiel #2
0
 public void EndsWithLy(string str, bool expected)
 {
     //arrange
     Strings obj = new Strings();
     //act
     bool actual = obj.EndsWithLy(str);
     //assert
     Assert.AreEqual(expected, actual);
 }
Beispiel #3
0
 public void ConCat(string a, string b, string expected)
 {
     //arrange
     Strings obj = new Strings();
     //act
     string actual = obj.ConCat(a, b);
     //assert
     Assert.AreEqual(expected, actual);
 }
Beispiel #4
0
        public void FirstHalf(string str, string expectedResult)
        {
            //Arrange
            Strings test = new Strings();

            //Act
            string actual = test.FirstHalf(str);

            //Assert
            Assert.AreEqual(expectedResult, actual);
        }
Beispiel #5
0
        public void EndsWithLy(string str, bool expectedResult)
        {
            //arrange: get your target class
            Strings test = new Strings();

            //Act : call the method you want to test
            bool actual = test.EndsWithLy(str);

            //Assert: assess target
            Assert.AreEqual(expectedResult, actual);
        }
Beispiel #6
0
        public void Concat(string a, string b, string expectedResult)
        {
            //Arrange: get your target class
            Strings test = new Strings();

            //Act: Call the method
            string actual = test.Concat(a, b);

            //Assert
            Assert.AreEqual(expectedResult, actual);
        }
Beispiel #7
0
        public void AbbaTest(string a, string b, string expectedResult)
        {
            //arrange
            Strings obj = new Strings();

            //act
            string actual = obj.Abba(a, b);

            //assert
            Assert.AreEqual(expectedResult, actual);
        }
        public void SayHiTest(string name, string expected)
        {
            // arrange
            Strings obj = new Strings();

            // act
            string actual = obj.SayHi(name);

            // assert
            Assert.AreEqual(expected, actual);
        }
Beispiel #9
0
        public void AtFirst(string str, string expectedResult)
        {
            //Arrange: get your target
            Strings test = new Strings();

            //Act: Call the method
            string actual = test.AtFirst(str);

            //Assert
            Assert.AreEqual(expectedResult, actual);
        }
Beispiel #10
0
 public void TrimOne(string str, string expectedResult)
 {
     //arrange
     Strings obj = new Strings();
     //act
     string actual = obj.TrimOne(str);
     //Assert
     Assert.AreEqual(expectedResult, actual);
 }
Beispiel #11
0
 public void TakeTwoFromPosition(string str, int n, string expected)
 {
     //arrange
     Strings obj = new Strings();
     //act
     string actual = obj.TakeTwoFromPosition(str, n);
     //assert
     Assert.AreEqual(expected, actual);
 }
Beispiel #12
0
 public void TakeOne(string str, bool fromFront, string expected)
 {
     //arrange
     Strings obj = new Strings();
     //act
     string actual = obj.TakeOne(str, fromFront);
     //assert
     Assert.AreEqual(expected, actual);
 }
Beispiel #13
0
 public void SwapLast(string str, string expected)
 {
     //arrange
     Strings obj = new Strings();
     //act
     string actual = obj.SwapLast(str);
     //assert
     Assert.AreEqual(expected, actual);
 }
Beispiel #14
0
 public void FrontAndBack(string a, int b, string expResult)
 {
     Strings obj = new Strings();
     string actual = obj.FrontAndBack(a, b);
     Assert.AreEqual(expResult, actual);
 }
Beispiel #15
0
 public void FrontAgain(string str, bool expected)
 {
     //arrange
     Strings obj = new Strings();
     //act
     bool actual = obj.FrontAgain(str);
     //assert
     Assert.AreEqual(expected, actual);
 }
Beispiel #16
0
 public void EndsWithLy(string a, bool expResult)
 {
     Strings obj = new Strings();
     bool actual = obj.EndsWithLy(a);
     Assert.AreEqual(actual, expResult);
 }
Beispiel #17
0
 public void MakeTags(string tag, string content, string expectedResult)
 {
     //arrange
     Strings obj = new Strings();
     //act
     string actual = obj.MakeTags(tag, content);
     //assert
     Assert.AreEqual(expectedResult, actual);
 }
Beispiel #18
0
 public void LastChars(string a, string b, string expected)
 {
     //arrange
     Strings obj = new Strings();
     //act
     string actual = obj.LastChars(a, b);
     //assert
     Assert.AreEqual(expected, actual);
 }
Beispiel #19
0
 public void LongInMiddle(string a, string b, string expected)
 {
     //arrange
     Strings obj = new Strings();
     //act
     string actual = obj.LongInMiddle(a, b);
     //assert
     Assert.AreEqual(expected, actual);
 }
Beispiel #20
0
 public void InsertWord(string container, string word, string expectedResult)
 {
     //arrange
     Strings obj = new Strings();
     //act
     string actual = obj.InsertWord(container, word);
     //assert
     Assert.AreEqual(expectedResult, actual);
 }
Beispiel #21
0
 public void InsertWord(string a, string b, string expResult)
 {
     Strings obj = new Strings();
     string actual = obj.InsertWord(a, b);
     Assert.AreEqual(expResult, actual);
 }
Beispiel #22
0
 public void HasBad(string a, bool expResult)
 {
     Strings obj = new Strings();
     bool actual = obj.HasBad(a);
     Assert.AreEqual(actual, expResult);
 }
Beispiel #23
0
 public void TweakFront(string str, string expected)
 {
     //arrange
     Strings obj = new Strings();
     //act
     string actual = obj.TweakFront(str);
     //assert
     Assert.AreEqual(expected, actual);
 }
Beispiel #24
0
 public void MiddleTwo(string str, string expected)
 {
     //arrange
     Strings obj = new Strings();
     //act
     string actual = obj.MiddleTwo(str);
     //assert
     Assert.AreEqual(expected, actual);
 }
Beispiel #25
0
 public void FirstHalf(string a, string expResult)
 {
     Strings obj = new Strings();
     string actual = obj.FirstHalf(a);
     Assert.AreEqual(expResult, actual);
 }
Beispiel #26
0
 public void MultipleEndings(string str, string expectedResult)
 {
     //arrange
     Strings obj = new Strings();
     //act
     string actual = obj.MultipleEndings(str);
     //assert
     Assert.AreEqual(expectedResult, actual);
 }
Beispiel #27
0
 public void ConCat(string a, string b, string expResult)
 {
     Strings obj = new Strings();
     string actual = obj.ConCat(a, b);
     Assert.AreEqual(expResult, actual);
 }
Beispiel #28
0
 public void RotateRight2(string str, string expected)
 {
     //arrange
     Strings obj = new Strings();
     //act
     string actual = obj.Rotateright2(str);
     //assert
     Assert.AreEqual(expected, actual);
 }
Beispiel #29
0
 public void FrontAndBack(string str, int n, string expected)
 {
     //arrange
     Strings obj = new Strings();
     //act
     string actual = obj.FrontAndBack(str, n);
     //assert
     Assert.AreEqual(expected, actual);
 }
Beispiel #30
0
 public void FrontAgain(string a, bool expResult)
 {
     Strings obj = new Strings();
     bool actual = obj.FrontAgain(a);
     Assert.AreEqual(actual, expResult);
 }