# 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_with_none,
    vut_style_tabledata,
    vut_styles,
)
from .._common import regexp_ansi_escape, strip_ansi_escape
import pytest
import pytablewriter as ptw
        writer = table_writer_class()
        writer.table_name = table
        writer.set_indent_level(indent)
        writer.headers = header
        writer.value_matrix = value
        writer.write_table()

        out, err = capsys.readouterr()
        print_test_result(expected=expected, actual=out, error=err)

        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(
            """\
            .. table:: style test

                ====  =====  ====  =====  ======  =====  ============  ========  ========  =============
                none  empty  tiny  small  medium  large  null w/ bold   L bold   S italic  L bold italic
                ====  =====  ====  =====  ======  =====  ============  ========  ========  =============
                 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_simple_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_with_none,
    vut_style_tabledata,
    vut_styles,
)
from .._common import regexp_ansi_escape, strip_ansi_escape
import pytest
import pytablewriter as ptw

        writer = table_writer_class()
        writer.table_name = table
        writer.set_indent_level(indent)
        writer.headers = header
        writer.value_matrix = value
        writer.write_table()

        out, err = capsys.readouterr()
        print_test_result(expected=expected, actual=out, error=err)

        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(
            """\
            .. table:: style test

                ====  =====  ====  =====  ======  =====  ============  ========  ========  =============
                none  empty  tiny  small  medium  large  null w/ bold   L bold   S italic  L bold italic
                ====  =====  ====  =====  ======  =====  ============  ========  ========  =============
                 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)