예제 #1
0
        public void GivenStringAttribute_ThenReturnsProperRecordForIt()
        {
            LabelAttribute la       = new LabelAttribute("b");
            DotHelper      dh       = new DotHelper();
            string         record   = dh.GetRecordFromAttribute(la);
            string         expected = la.Key + "=b";

            Assert.Equal(expected, record);
        }
예제 #2
0
        public void GivenColorAttribute_ThenReturnsProperRecordForIt()
        {
            string             hexColor           = "#C6C6C6";
            IGraphVizColor     colorValue         = GraphVizColor.FromHex(hexColor);
            FillColorAttribute fillColorAttribute = new FillColorAttribute(colorValue);
            DotHelper          dh       = new DotHelper();
            string             record   = dh.GetRecordFromAttribute(fillColorAttribute);
            string             expected = $"{fillColorAttribute.Key}=\"#C6C6C6\"";

            Assert.Equal(expected, record);
        }