# Path: test/_common.py
# def print_test_result(expected, actual, error=None):
#     print(f"[expected]\n{expected}\n")
#     print(f"[actual]\n{actual}\n")
# 
#     if error:
#         print(error, file=sys.stderr)
# 
#     print("----------------------------------------")
# 
# Path: test/data.py
# TIME = datetime.datetime(2017, 1, 1, 0, 0, 0)
# INF = float("inf")
# NAN = float("nan")
# 
# Path: test/writer/text/_common.py
# def strip_ansi_escape(value):


from textwrap import dedent
from ...._common import print_test_result
from ....data import (
    Data,
    headers,
    mix_header_list,
    mix_value_matrix,
    null_test_data_list,
    value_matrix,
    value_matrix_iter,
    value_matrix_with_none,
    vut_style_tabledata,
    vut_styles,
)
from .._common import regexp_ansi_escape, strip_ansi_escape
import pytest
import pytablewriter
        ],
    )
    def test_normal(self, table, indent, header, value, expected):
        writer = table_writer_class()
        writer.table_name = table
        writer.set_indent_level(indent)
        writer.headers = header
        writer.value_matrix = value

        out = writer.dumps()
        print_test_result(expected=expected, actual=out)

        assert out == expected

    def test_normal_styles(self):
        writer = table_writer_class()
        writer.from_tabledata(vut_style_tabledata)
        writer.column_styles = vut_styles

        expected = dedent(
            """\
            .. csv-table:: style test
                :header: "none", "empty", "tiny", "small", "medium", "large", "null w/ bold", "L bold", "S italic", "L bold italic"
                :widths: 6, 7, 6, 7, 8, 7, 14, 8, 10, 15

                111, 111, 111, 111, "111", 111, , **111**, *111*, **111**
                1234, 1234, 1234, 1234, "1,234", 1 234, , **1234**, *1234*, **1234**
            """
        )
        out = writer.dumps()

# Path: test/_common.py
# def print_test_result(expected, actual, error=None):
#     print(f"[expected]\n{expected}\n")
#     print(f"[actual]\n{actual}\n")
# 
#     if error:
#         print(error, file=sys.stderr)
# 
#     print("----------------------------------------")
# 
# Path: test/data.py
# TIME = datetime.datetime(2017, 1, 1, 0, 0, 0)
# INF = float("inf")
# NAN = float("nan")
# 
# Path: test/writer/text/_common.py
# def strip_ansi_escape(value):


# Path: test/writer/text/rst/test_rst_csv_writer.py
from textwrap import dedent
from ...._common import print_test_result
from ....data import (
    Data,
    headers,
    mix_header_list,
    mix_value_matrix,
    null_test_data_list,
    value_matrix,
    value_matrix_iter,
    value_matrix_with_none,
    vut_style_tabledata,
    vut_styles,
)
from .._common import regexp_ansi_escape, strip_ansi_escape
import pytest
import pytablewriter

        ],
    )
    def test_normal(self, table, indent, header, value, expected):
        writer = table_writer_class()
        writer.table_name = table
        writer.set_indent_level(indent)
        writer.headers = header
        writer.value_matrix = value

        out = writer.dumps()
        print_test_result(expected=expected, actual=out)

        assert out == expected

    def test_normal_styles(self):
        writer = table_writer_class()
        writer.from_tabledata(vut_style_tabledata)
        writer.column_styles = vut_styles

        expected = dedent(
            """\
            .. csv-table:: style test
                :header: "none", "empty", "tiny", "small", "medium", "large", "null w/ bold", "L bold", "S italic", "L bold italic"
                :widths: 6, 7, 6, 7, 8, 7, 14, 8, 10, 15

                111, 111, 111, 111, "111", 111, , **111**, *111*, **111**
                1234, 1234, 1234, 1234, "1,234", 1 234, , **1234**, *1234*, **1234**
            """
        )
        out = writer.dumps()

        print_test_result(expected=expected, actual=out)