Пример #1
0
        public int Seek_positivTest(string text, string element)
        {
            FileStorage storage    = new FileStorage();
            WordsSeeker wordSeeker = new WordsSeeker();

            wordSeeker.Text = text;
            wordSeeker.SaveData(storage);
            wordSeeker = new WordsSeeker();
            wordSeeker.LoadData(storage);
            return(wordSeeker.Seek(element));
        }
Пример #2
0
        public void Seek_Exeption(string text, string element)
        {
            FileStorage storage    = new FileStorage();
            WordsSeeker wordSeeker = new WordsSeeker();

            wordSeeker.Text = text;
            wordSeeker.SaveData(storage);
            wordSeeker = new WordsSeeker();
            wordSeeker.LoadData(storage);
            Assert.Throws <ArgumentNullException> (() => wordSeeker.Seek(element));
        }