Beispiel #1
0
 public void GetFilmFromImdbTest()
 {
     var title = "A Knights Tale"; // TODO: Initialize to an appropriate value
     var source = FilmFetcher.Source.Imdb; // TODO: Initialize to an appropriate value
     var target = new FilmFetcher(title, source); // TODO: Initialize to an appropriate value
     Assert.Inconclusive("A method that does not return a value cannot be verified.");
 }
Beispiel #2
0
 public void AddFilmTest()
 {
     Context.Bootstrap();
     var film = new FilmFetcher("Matrix").Film;
     var add = new Add();
     var actual = add.AddFilm(film);
     var id = Komodo.Core.Database.Index.Search.Search.SearchFilm("Matrix");
     Assert.AreNotEqual("",id[0]);
 }
Beispiel #3
0
        public void IndexTest()
        {
            Film film = new FilmFetcher("Matrix").Film; // TODO: Initialize to an appropriate value
            Film f1 = new FilmFetcher("Lethal Weapon").Film;
            Indexer.Index(film);
            Indexer.Index(f1);

            var r = Core.Database.Index.Search.Search.SearchFilm("Matrix");

            Assert.Inconclusive("A method that does not return a value cannot be verified.");
        }
Beispiel #4
0
 public void Run()
 {
     _str1 = "Fetching Films";
     _taskLabel.BeginInvoke(new MethodInvoker(UpdateTaskLabel));
     foreach (var folder in _folders)
     {
         var title = folder.Remove(0, folder.LastIndexOf('\\') + 1);
         _str = "Searching for " + title;
         _label.BeginInvoke(new MethodInvoker(UpdateLabel));
         var film = new FilmFetcher(title).Film;
         if(film.Url == null)
             Errors.Add(film);
         else
             Films.Add(film);
     }
     _addFilms.Errors.AddRange(Errors);
     _addFilms.Films.AddRange(Films);
     _semaphore.Signal();
 }