# 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")


import collections
import datetime
import json
import elasticsearch
import pytest
import pytablewriter as ptw
from decimal import Decimal
from .._common import print_test_result
from ..data import headers, value_matrix
            {
                "text": "This is XXX",
                "byte": 100,
                "short": 10000,
                "int": 2000000000,
                "long": 200000000000,
                "float": Decimal("0.1"),
                "date": "2017-01-03T04:05:06",
                "bool": True,
                "ip": "127.0.0.1",
                "none": None,
                "inf": "Infinity",
                "nan": "NaN",
            },
            {
                "text": "What is it",
                "byte": -10,
                "short": -1000,
                "int": -200000000,
                "long": -20000000000,
                "float": Decimal("100.1"),
                "date": "2017-01-03T04:05:06",
                "bool": False,
                "ip": "::1",
                "none": None,
                "inf": "Infinity",
                "nan": "NaN",
            },
        ]


# 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/test_elasticsearch_writer.py
import collections
import datetime
import json
import elasticsearch
import pytest
import pytablewriter as ptw
from decimal import Decimal
from .._common import print_test_result
from ..data import headers, value_matrix

            {
                "text": "This is XXX",
                "byte": 100,
                "short": 10000,
                "int": 2000000000,
                "long": 200000000000,
                "float": Decimal("0.1"),
                "date": "2017-01-03T04:05:06",
                "bool": True,
                "ip": "127.0.0.1",
                "none": None,
                "inf": "Infinity",
                "nan": "NaN",
            },
            {
                "text": "What is it",
                "byte": -10,
                "short": -1000,
                "int": -200000000,
                "long": -20000000000,
                "float": Decimal("100.1"),
                "date": "2017-01-03T04:05:06",
                "bool": False,
                "ip": "::1",
                "none": None,
                "inf": "Infinity",
                "nan": "NaN",
            },
        ]


        print_test_result(expected=expected_body, actual=body)