public void generate_should_return_code_with_item()
        {
            // Given
            var enumerate = new Enumerate();

            enumerate.AddItem("My item");

            // When
            var result = SUT.Generate(enumerate);

            // Then
            Assert.AreEqual(@"\begin{enumerate}" + "\n\t" + @"\item My item" + "\n" + @" \end{enumerate}" + "\n", result);
        }
Beispiel #2
0
        /// <summary>
        /// Returns a string that represents the current object.
        /// </summary>
        /// <returns>
        /// A string that represents the current object.
        /// </returns>
        public override string ToString()
        {
            var codeGenerator = new EnumerateCodeGenerator();

            return(codeGenerator.Generate(this));
        }