-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
3 changed files
with
146 additions
and
17 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
Feb 08, 2024 12:50:46 PM LectorPeliculas main | ||
SEVERE: Finalizada la lectura del archivo | ||
Feb 08, 2024 12:50:46 PM LectorPeliculas main | ||
WARNING: Creado el diccionario de peliculas | ||
Feb 08, 2024 12:50:46 PM LectorPeliculas main | ||
INFO: [Ellen Burstyn, Jared Leto, Jennifer Connelly, Marlon Wayans] | ||
Feb 08, 2024 12:50:46 PM LectorPeliculas calculaConjuntoActores | ||
FINEST: Ha tardado: 1 | ||
Feb 08, 2024 12:50:46 PM LectorPeliculas main | ||
INFO: Actores únicos: 2003 | ||
Feb 08, 2024 12:50:46 PM LectorPeliculas main | ||
FINE: 2003 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,47 @@ | ||
import static org.junit.jupiter.api.Assertions.*; | ||
|
||
import java.util.List; | ||
import java.util.Map; | ||
import java.util.Set; | ||
|
||
import org.junit.jupiter.api.BeforeAll; | ||
import org.junit.jupiter.api.Test; | ||
|
||
class TestLectorPeliculas { | ||
|
||
static List<String> lineas; | ||
static Map<String, List<String>> peliculas, actorPelicula; | ||
|
||
@BeforeAll | ||
public static void setUp() { | ||
try { | ||
lineas = LectorPeliculas.getLineasDeArchivo("peliculas.tsv"); | ||
peliculas = LectorPeliculas.crearDiccionarioPeliculas(lineas); | ||
|
||
actorPelicula = LectorPeliculas.invierteDiccionarioPeliculas(peliculas); | ||
} catch (Exception e) { | ||
|
||
} | ||
} | ||
|
||
@Test | ||
void testGetLineasDeArchivo() { | ||
try { | ||
List<String> lineas = LectorPeliculas.getLineasDeArchivo("peliculas.tsv"); | ||
assertEquals(599, lineas.size()); | ||
} catch (Exception e) { | ||
fail("El método lanzó una excepción"); | ||
} | ||
} | ||
|
||
@Test | ||
void testActorConMasPelis() { | ||
|
||
|
||
assertEquals(6, LectorPeliculas.getMaxPeliculas(actorPelicula)); | ||
|
||
|
||
} | ||
|
||
|
||
} |