public void Read_WrongTweetFilePath_ReturnsException()
        {
            string directoryPath = "x:\\WrongFilePath";
               TweetFileReader fileReader = new TweetFileReader(directoryPath);

              fileReader.Read();
        }
        public void Read_ValidTweetFile_ReturnsListOfTweeets()
        {
            string directoryPath = Directory.GetParent(Directory.GetCurrentDirectory()).Parent.FullName;
            TweetFileReader fileReader = new TweetFileReader(directoryPath);

            List<Tweet> results = fileReader.Read();

            Assert.AreEqual(3, results.Count);
            Assert.AreEqual("Alan", results[0].Name);
        }
Ejemplo n.º 3
0
 public List<Tweet> GetTweets(string path = "")
 {
     var fileReader = new TweetFileReader(path);
     var results = fileReader.Read();
     return results;
 }