// Path: src/test/java/io/github/marioluan/datastructures/factory/DirectedAcyclicGraphFactory.java
// public final class DirectedAcyclicGraphFactory {
//     /**
//      * Builds a graph with the same vertices and edges from lecture slides. <br>
//      * <strong>https://algs4.cs.princeton.edu/lectures/42DirectedGraphs.pdf</strong>
//      */
//     public static Graph build() {
//         Graph graph = new Digraph(7);
// 
//         graph.addEdge(0, 2);
//         graph.addEdge(0, 5);
//         graph.addEdge(0, 1);
// 
//         graph.addEdge(1, 4);
// 
//         graph.addEdge(5, 2);
// 
//         graph.addEdge(3, 6);
//         graph.addEdge(3, 2);
//         graph.addEdge(3, 5);
//         graph.addEdge(3, 4);
// 
//         graph.addEdge(6, 0);
//         graph.addEdge(6, 4);
// 
// 
//         return graph;
//     }
// }
// 
// Path: src/main/java/io/github/marioluan/datastructures/graph/Graph.java
// public interface Graph {
// 
//     /**
//      * Adds an edge v-w.
//      *
//      * @param v vertex v
//      * @param w vertex w
//      */
//     void addEdge(int v, int w);
// 
//     /**
//      * Returns the vertices adjacent to v.
//      *
//      * @param v vertex v
//      * @return vertices adjacent to v
//      */
//     Iterable<Integer> adj(int v);
// 
//     /**
//      * Returns the number of vertices.
//      *
//      * @return number of vertices
//      */
//     int V();
// 
//     /**
//      * Returns the number of edges.
//      *
//      * @return number of edges
//      */
//     int E();
// 
//     /**
//      * Returns its reverse order.
//      *
//      * @return its reverse order
//      */
//     Graph reverse();
// 
//     /**
//      * Returns its string representation.
//      *
//      * @return string representation
//      */
//     String toString();
// }


import com.greghaskins.spectrum.Spectrum;
import static com.greghaskins.spectrum.Spectrum.*;
import io.github.marioluan.datastructures.factory.DirectedAcyclicGraphFactory;
import io.github.marioluan.datastructures.graph.Graph;
import org.junit.Assert;
import org.junit.runner.RunWith;
package io.github.marioluan.datastructures.graph.sort;




@RunWith(Spectrum.class)
public class TopologicalSortTest {
    private Graph graph;
    private TopologicalSort subject;

    {
        describe("TopologicalSort", () -> {
            beforeEach(() -> {
// Path: src/test/java/io/github/marioluan/datastructures/factory/DirectedAcyclicGraphFactory.java
// public final class DirectedAcyclicGraphFactory {
//     /**
//      * Builds a graph with the same vertices and edges from lecture slides. <br>
//      * <strong>https://algs4.cs.princeton.edu/lectures/42DirectedGraphs.pdf</strong>
//      */
//     public static Graph build() {
//         Graph graph = new Digraph(7);
// 
//         graph.addEdge(0, 2);
//         graph.addEdge(0, 5);
//         graph.addEdge(0, 1);
// 
//         graph.addEdge(1, 4);
// 
//         graph.addEdge(5, 2);
// 
//         graph.addEdge(3, 6);
//         graph.addEdge(3, 2);
//         graph.addEdge(3, 5);
//         graph.addEdge(3, 4);
// 
//         graph.addEdge(6, 0);
//         graph.addEdge(6, 4);
// 
// 
//         return graph;
//     }
// }
// 
// Path: src/main/java/io/github/marioluan/datastructures/graph/Graph.java
// public interface Graph {
// 
//     /**
//      * Adds an edge v-w.
//      *
//      * @param v vertex v
//      * @param w vertex w
//      */
//     void addEdge(int v, int w);
// 
//     /**
//      * Returns the vertices adjacent to v.
//      *
//      * @param v vertex v
//      * @return vertices adjacent to v
//      */
//     Iterable<Integer> adj(int v);
// 
//     /**
//      * Returns the number of vertices.
//      *
//      * @return number of vertices
//      */
//     int V();
// 
//     /**
//      * Returns the number of edges.
//      *
//      * @return number of edges
//      */
//     int E();
// 
//     /**
//      * Returns its reverse order.
//      *
//      * @return its reverse order
//      */
//     Graph reverse();
// 
//     /**
//      * Returns its string representation.
//      *
//      * @return string representation
//      */
//     String toString();
// }


// Path: src/test/java/io/github/marioluan/datastructures/graph/sort/TopologicalSortTest.java
import com.greghaskins.spectrum.Spectrum;
import static com.greghaskins.spectrum.Spectrum.*;
import io.github.marioluan.datastructures.factory.DirectedAcyclicGraphFactory;
import io.github.marioluan.datastructures.graph.Graph;
import org.junit.Assert;
import org.junit.runner.RunWith;

package io.github.marioluan.datastructures.graph.sort;




@RunWith(Spectrum.class)
public class TopologicalSortTest {
    private Graph graph;
    private TopologicalSort subject;

    {
        describe("TopologicalSort", () -> {
            beforeEach(() -> {
                graph = DirectedAcyclicGraphFactory.build();