Example #1
0
        public void IsUnique_EmptyString_Test()
        {
            BruteForceSolution bruteForceSolution = new BruteForceSolution();
            var  inputString = string.Empty;
            bool actual      = bruteForceSolution.IsUnique(inputString);

            Assert.AreEqual(true, actual);
        }
Example #2
0
        public void IsUnique_LargeInput_Test()
        {
            BruteForceSolution bruteForceSolution = new BruteForceSolution();

            var  inputString = StringUtilities.CreateLargeString();
            bool actual      = bruteForceSolution.IsUnique(inputString);

            Trace.WriteLine(inputString);
            Trace.WriteLine(actual);
        }
Example #3
0
        public void IsUnique_SmallInput_NotUnique_Test_3()
        {
            BruteForceSolution bruteForceSolution = new BruteForceSolution();

            var  inputString = "gghjyer";
            bool expectedAllCharactersUnique = false;
            bool actualAllCharactersUnique   = bruteForceSolution.IsUnique(inputString);

            Assert.AreEqual(expectedAllCharactersUnique, actualAllCharactersUnique);
        }