Beispiel #1
0
        public void GenerateTextEmpty()
        {
            var cube = new An8Cube();

            var text = cube.GenerateText();

            string expected =
                @"cube {
  name { """" }
  scale { 0.000000 0.000000 0.000000 }
  divisions { 0 0 0 }
}
";

            Assert.Equal(
                expected.Replace("\r\n", "\n"),
                text.Replace("\r\n", "\n"));
        }
Beispiel #2
0
        public void GenerateTextDivisions()
        {
            var cube = new An8Cube();

            cube.DivisionsX = 2;
            cube.DivisionsY = 3;
            cube.DivisionsZ = 4;

            var text = cube.GenerateText();

            string expected =
                @"cube {
  name { """" }
  scale { 0.000000 0.000000 0.000000 }
  divisions { 2 3 4 }
}
";

            Assert.Equal(
                expected.Replace("\r\n", "\n"),
                text.Replace("\r\n", "\n"));
        }
Beispiel #3
0
        public void GenerateTextScale()
        {
            var cube = new An8Cube();

            cube.ScaleX = 2.0f;
            cube.ScaleY = 3.0f;
            cube.ScaleZ = 4.0f;

            var text = cube.GenerateText();

            string expected =
                @"cube {
  name { """" }
  scale { 2.000000 3.000000 4.000000 }
  divisions { 0 0 0 }
}
";

            Assert.Equal(
                expected.Replace("\r\n", "\n"),
                text.Replace("\r\n", "\n"));
        }