Пример #1
0
        public void SearchSeries_GameOfThrones_WillReturn_1Item()
        {
            //arrange
            var tvdb = new TVDBNet(YourTheTVDBAPIKey);

            //act
            var results = tvdb.GetSeries("Game of Thrones").ToList();

            //Assert
            Assert.True(results.Any());
            Assert.True(results.Count == 1, "Expected 1 but {0}", results.Count);
        }
Пример #2
0
        public void GetMirrors_Tests()
        {
            //arrange
            var tvdb = new TVDBNet(YourTheTVDBAPIKey);

            //act
            

            //Assert
            Assert.True(tvdb.Mirrors.Any());
     
           
        }
Пример #3
0
        public void SearchSeries_PawnStars()
        {
            //arrange
            var tvdb = new TVDBNet(YourTheTVDBAPIKey);

            //act
            var results = tvdb.GetSeries("Pawn Stars").ToList();

            //Assert
            Assert.True(results.Any());
            results.ForEach(r=> Debug.WriteLine(r.SeriesName));
            //Assert.True(results.Count == 1, "Expected 1 but {0}", results.Count);
        }
Пример #4
0
        public void GetServerTime_Tests()
        {
            //arrange
            var tvdb = new TVDBNet(YourTheTVDBAPIKey);

            //act
         

            //Assert
            Assert.True(tvdb.ServerTime != default(DateTime));


        }
Пример #5
0
 public void Constructor_EmtptyNullApiKey_ThrowsException()
 {
     //arrange
     //act
     var tvdb = new TVDBNet("");
 }