Ejemplo n.º 1
0
        public void IsIt(string query, bool isAllowed)
        {
            var setIntervalCommand = new SetIntervalValueCommand();
            var value = setIntervalCommand.IsIt(query);

            Debug.WriteLine(value);
            if (value != isAllowed)
            {
                throw new Exception();
            }
        }
Ejemplo n.º 2
0
        public void TestMethod1()
        {
            var setIntervalCommand = new SetIntervalValueCommand();
            var value = setIntervalCommand.ExtractValue("по 3 часов");

            Debug.WriteLine(value);
            if (value != 3)
            {
                throw new Exception();
            }
        }
Ejemplo n.º 3
0
        public void TestMethod4()
        {
            var setIntervalCommand = new SetIntervalValueCommand();
            var value = setIntervalCommand.ExtractValue("по00,00часа");

            Debug.WriteLine(value);
            if (value != (decimal)0)
            {
                throw new Exception();
            }
        }
        public void ExtractQuery(string strSource, string strResult)
        {
            var setIntervalCommand = new SetIntervalValueCommand();
            var value = setIntervalCommand.ExtractQuery(strSource);

            Debug.WriteLine(value);
            if (value != strResult)
            {
                throw new Exception();
            }
        }