Comparar commits
2 commits
e728c77982
...
72b117f83b
| Autor | SHA1 | Fecha | |
|---|---|---|---|
| 72b117f83b | |||
| f6f431fce1 |
Se han modificado 1 ficheros con 6 adiciones y 1 borrados
|
|
@ -15,6 +15,7 @@ import org.insa.graphs.model.io.BinaryGraphReader;
|
||||||
import org.insa.graphs.model.io.BinaryPathReader;
|
import org.insa.graphs.model.io.BinaryPathReader;
|
||||||
import org.insa.graphs.model.io.GraphReader;
|
import org.insa.graphs.model.io.GraphReader;
|
||||||
import org.insa.graphs.model.io.PathReader;
|
import org.insa.graphs.model.io.PathReader;
|
||||||
|
import org.junit.BeforeClass;
|
||||||
import org.junit.Test;
|
import org.junit.Test;
|
||||||
|
|
||||||
public class DijkstraAlgorithmTest {
|
public class DijkstraAlgorithmTest {
|
||||||
|
|
@ -26,7 +27,7 @@ public class DijkstraAlgorithmTest {
|
||||||
public Path path;
|
public Path path;
|
||||||
|
|
||||||
|
|
||||||
//@Before
|
@BeforeClass
|
||||||
public void init() {
|
public void init() {
|
||||||
// Visit these directory to see the list of available files on Commetud.
|
// Visit these directory to see the list of available files on Commetud.
|
||||||
// When running with VSC, paths are relative to the BE_Graphes directory.
|
// When running with VSC, paths are relative to the BE_Graphes directory.
|
||||||
|
|
@ -40,9 +41,13 @@ public class DijkstraAlgorithmTest {
|
||||||
|
|
||||||
// Read the graph. X
|
// Read the graph. X
|
||||||
this.graph = reader.read();
|
this.graph = reader.read();
|
||||||
|
// free resources
|
||||||
|
reader.close();
|
||||||
|
|
||||||
// Create a PathReader.
|
// Create a PathReader.
|
||||||
final PathReader pathReader = new BinaryPathReader(new DataInputStream(new BufferedInputStream(new FileInputStream(pathName))));
|
final PathReader pathReader = new BinaryPathReader(new DataInputStream(new BufferedInputStream(new FileInputStream(pathName))));
|
||||||
|
// free resources
|
||||||
|
pathReader.close();
|
||||||
|
|
||||||
// Read the path.
|
// Read the path.
|
||||||
this.path = pathReader.readPath(graph);
|
this.path = pathReader.readPath(graph);
|
||||||
|
|
|
||||||
Cargando…
Referenciar en una nueva incidencia