コード例 #1
0
        public void TestFindTheLongestWord_Positive()
        {
            //Arrange
            var expected = "yesterday";
            //Act
            var result = StringArrayLinq.FindTheLongestWord(strings);

            //Assert
            Assert.AreEqual(expected, result);
        }
コード例 #2
0
        public void TestFindTheLongestWord_CompareWithOrdering()
        {
            //Arrange
            var expected = true;
            //Act
            var result             = StringArrayLinq.FindTheLongestWord(strings);
            var resultFromOrdering = StringArrayLinq.FindTheLongestWordWithOrdering(strings);

            //Assert
            Assert.AreEqual(expected, result == resultFromOrdering);
        }