public void FillWithOneColor_FillsExpectedVertices([NotNull] string relationships, char startVertex,
                                                           string expected)
        {
            var graph  = new LiteralGraph(relationships, true);
            var result = new List <char>();

            graph.FillWithOneColor(startVertex, vertex => result.Add(vertex));

            Assert.AreEqual(expected, string.Join(",", result));
        }
        public void FillWithOneColor_ThrowsException_ForNullApplyColor()
        {
            var graph = new LiteralGraph("A>1>B", true);

            Assert.Throws <ArgumentNullException>(() => graph.FillWithOneColor('A', null));
        }
        public void FillWithOneColor_ThrowsException_ForInvalidVertex()
        {
            var graph = new LiteralGraph("A>1>B", true);

            Assert.Throws <ArgumentException>(() => graph.FillWithOneColor('Z', v => { }));
        }