Exemplo n.º 1
0
        public async Task Db_GetMovie()
        {
            using (var db = await MockMovie.CreateAsync(CreateDb()))
            {
                var result = await db.GetMovieAsync(1);

                Assert.AreEqual(1, result.Count);
            }
        }
Exemplo n.º 2
0
        public async Task Db_GetMovies()
        {
            using (var db = await MockMovie.CreateAsync(CreateDb()))
            {
                var result = await db.GetMoviesAsync("comedy");

                Assert.AreEqual(3, result.Count);
            }

            using (var db = await MockMovie.CreateAsync(CreateDb()))
            {
                var result = await db.GetMoviesAsync("ghost");

                Assert.AreEqual(2, result.Count);
            }
        }