コード例 #1
0
        public void PerformanceTestGetAvgMovieRating()
        {
            Stopwatch sw = Stopwatch.StartNew();;

            movieProgram.GetAvgMovieRating(1488844);
            sw.Stop();

            var seconds = sw.ElapsedMilliseconds / 1000.0;

            Assert.IsTrue(seconds <= MAXTIME);
        }
コード例 #2
0
        public void TestGetAvgMovieRatingException()
        {
            MovieProgram movieProgram = new MovieProgram("MovieReviewEASV/Test.json");

            movieProgram.GetAvgMovieRating(885014);
        }
コード例 #3
0
        public void TestGetAvgMovieRating()
        {
            MovieProgram movieProgram = new MovieProgram("MovieReviewEASV/Test.json");

            Assert.AreEqual(3, movieProgram.GetAvgMovieRating(1488844));
        }