예제 #1
0
        public void IsRegEx_HandlesType_ReturnsIsRegExType()
        {
            var decisionType = enDecisionType.IsRegEx;
            //------------Setup for test--------------------------
            var isRegEx = new IsRegEx();

            //------------Execute Test---------------------------
            //------------Assert Results-------------------------
            Assert.AreEqual(decisionType, isRegEx.HandlesType());
        }
예제 #2
0
        public void GivenSomeString_IsRegEx_Invoke_ReturnsFalse()
        {
            //------------Setup for test--------------------------
            var isRegEx = new IsRegEx();

            string[] cols = new string[2];
            cols[0] = "Number 5 should";
            cols[1] = "d";
            //------------Execute Test---------------------------
            bool result = isRegEx.Invoke(cols);

            //------------Assert Results-------------------------
            Assert.IsTrue(result);
        }
예제 #3
0
        public void IsRegEx_Invoke_IsRegEx_ReturnsTrue()
        {
            //------------Setup for test--------------------------
            var notStartsWith = new IsRegEx();

            string[] cols = new string[2];
            cols[0] = "324";
            cols[1] = "d";
            //------------Execute Test---------------------------
            bool result = notStartsWith.Invoke(cols);

            //------------Assert Results-------------------------
            Assert.IsFalse(result);
        }
예제 #4
0
 public void SaveToRegistry()
 {
     SaveValueToRegistry("Dir", Dir);
     SaveValueToRegistry("IncludeSubDirectories", IncludeSubDirectories.ToString());
     SaveValueToRegistry("FileMask", FileMask);
     SaveValueToRegistry("ExcludeFileMask", ExcludeFileMask);
     SaveValueToRegistry("FindText", FindText);
     SaveValueToRegistry("IsCaseSensitive", IsCaseSensitive.ToString());
     SaveValueToRegistry("IsRegEx", IsRegEx.ToString());
     SaveValueToRegistry("SkipBinaryFileDetection", SkipBinaryFileDetection.ToString());
     SaveValueToRegistry("ShowEncoding", ShowEncoding.ToString());
     SaveValueToRegistry("IncludeFilesWithoutMatches", IncludeFilesWithoutMatches.ToString());
     SaveValueToRegistry("ReplaceText", ReplaceText);
     SaveValueToRegistry("UseEscapeChars", UseEscapeChars.ToString());
     SaveValueToRegistry("Encoding", Encoding);
 }