public void NullFileNameThoughtWorksRailNetworkReaderTest()
        {
            var  tr = GraphReaderFactory.Create("ThoughtWorks", "sample", Directionality.Unidirectional);
            bool rc = tr.Read(null);

            Assert.IsTrue(rc, "There was a problem with reading the graph file");
        }
        public void BadDriverThoughtWorksRailNetworkReaderTest()
        {
            var  tr = GraphReaderFactory.Create("FooBaz", "sample", Directionality.Unidirectional);
            bool rc = tr.Read("ThoughtWorksRailNetwork.txt");

            Assert.IsTrue(rc, "There was a problem with reading the graph file");
        }
        public void TestCreatingBidirectionalGraph()
        {
            var tr = GraphReaderFactory.Create("ThoughtWorks", "sample", Directionality.Bidirectional);

            this.Graph = tr.Graph;
            Assert.IsNotNull(Graph);

            // ReSharper disable once UnusedVariable
            PathGenerators pathGenerator = new PathGenerators(this.Graph);
        }
        public void ThoughtWorksRailNetworkReaderTest()
        {
            var  tr = GraphReaderFactory.Create("ThoughtWorks", "sample", Directionality.Unidirectional);
            bool rc = tr.Read("ThoughtWorksRailNetwork.txt");

            Assert.IsTrue(rc, "There was a problem with reading the graph file");

            Assert.IsNotNull(tr.Graph);
            Assert.IsTrue(tr.Graph.NumVertices == 5);
            Assert.IsTrue(tr.Graph.NumEdges == 9);
        }
        public void Initialize()
        {
            // Graph: AB5, BC4, CD8, DC8, DE6, AD5, CE2, EB3, AE7

            var  tr = GraphReaderFactory.Create("ThoughtWorks", "sample", Directionality.Unidirectional);
            bool rc = tr.Read("ThoughtWorksRailNetwork.txt");

            Assert.IsTrue(rc);

            this.Graph = tr.Graph;
            Assert.IsNotNull(Graph);
        }
示例#6
0
        public void Initialize()
        {
            // Graph: AB5, BC4, CD8, DC8, DE6, AD5, CE2, EB3, AE7

            var  tr = GraphReaderFactory.Create("ThoughtWorks", "sample", Directionality.Unidirectional);
            bool rc = tr.Read("ThoughtWorksRailNetwork.txt");

            if (!rc)
            {
                Console.WriteLine("Could not read the input file");
            }

            this.Graph = tr.Graph;
        }