# Path: test/converter/_common.py
# EXCEPTION_RESULT = "E"
# 
# def convert_wrapper(typeobj, method):
#     try:
#         return getattr(typeobj, method)()
#     except (typepy.TypeConversionError):
#         return EXCEPTION_RESULT


from decimal import Decimal
from ._common import EXCEPTION_RESULT, convert_wrapper
        from typepy import Nan, StrictLevel
import pytest
import typepy
            ["force_convert", 0, "test", EXCEPTION_RESULT],
            ["force_convert", 0, "", EXCEPTION_RESULT],
            ["force_convert", 1, 1, Decimal("1")],
            ["force_convert", 1, 1.0, Decimal("1.0")],
            ["force_convert", 1, 1.1, Decimal("1.1")],
            ["force_convert", 1, "0", Decimal("0")],
            ["force_convert", 1, "1.0", Decimal("1.0")],
            ["force_convert", 1, "1.1", Decimal("1.1")],
            ["force_convert", 1, True, Decimal("1")],
            ["force_convert", 1, None, EXCEPTION_RESULT],
            ["force_convert", 1, inf, Decimal("inf")],
            ["force_convert", 1, nan, Decimal("nan")],
            ["force_convert", 1, "test", EXCEPTION_RESULT],
            ["force_convert", 1, "", EXCEPTION_RESULT],
            ["force_convert", 2, 1, Decimal("1")],
            ["force_convert", 2, 1.0, Decimal("1.0")],
            ["force_convert", 2, 1.1, Decimal("1.1")],
            ["force_convert", 2, "0", Decimal("0")],
            ["force_convert", 2, "1.0", Decimal("1.0")],
            ["force_convert", 2, "1.1", Decimal("1.1")],
            ["force_convert", 2, True, Decimal("1")],
            ["force_convert", 2, None, EXCEPTION_RESULT],
            ["force_convert", 2, inf, Decimal("inf")],
            ["force_convert", 2, nan, Decimal("nan")],
            ["force_convert", 2, "test", EXCEPTION_RESULT],
            ["force_convert", 2, "", EXCEPTION_RESULT],
        ],
    )
    def test_normal(self, method, strict_level, value, expected):


# Path: test/converter/_common.py
# EXCEPTION_RESULT = "E"
# 
# def convert_wrapper(typeobj, method):
#     try:
#         return getattr(typeobj, method)()
#     except (typepy.TypeConversionError):
#         return EXCEPTION_RESULT


# Path: test/converter/test_realnumber.py
from decimal import Decimal
from ._common import EXCEPTION_RESULT, convert_wrapper
        from typepy import Nan, StrictLevel
import pytest
import typepy

            ["force_convert", 0, "test", EXCEPTION_RESULT],
            ["force_convert", 0, "", EXCEPTION_RESULT],
            ["force_convert", 1, 1, Decimal("1")],
            ["force_convert", 1, 1.0, Decimal("1.0")],
            ["force_convert", 1, 1.1, Decimal("1.1")],
            ["force_convert", 1, "0", Decimal("0")],
            ["force_convert", 1, "1.0", Decimal("1.0")],
            ["force_convert", 1, "1.1", Decimal("1.1")],
            ["force_convert", 1, True, Decimal("1")],
            ["force_convert", 1, None, EXCEPTION_RESULT],
            ["force_convert", 1, inf, Decimal("inf")],
            ["force_convert", 1, nan, Decimal("nan")],
            ["force_convert", 1, "test", EXCEPTION_RESULT],
            ["force_convert", 1, "", EXCEPTION_RESULT],
            ["force_convert", 2, 1, Decimal("1")],
            ["force_convert", 2, 1.0, Decimal("1.0")],
            ["force_convert", 2, 1.1, Decimal("1.1")],
            ["force_convert", 2, "0", Decimal("0")],
            ["force_convert", 2, "1.0", Decimal("1.0")],
            ["force_convert", 2, "1.1", Decimal("1.1")],
            ["force_convert", 2, True, Decimal("1")],
            ["force_convert", 2, None, EXCEPTION_RESULT],
            ["force_convert", 2, inf, Decimal("inf")],
            ["force_convert", 2, nan, Decimal("nan")],
            ["force_convert", 2, "test", EXCEPTION_RESULT],
            ["force_convert", 2, "", EXCEPTION_RESULT],
        ],
    )
    def test_normal(self, method, strict_level, value, expected):


        actual = convert_wrapper(typepy.RealNumber(value, strict_level), method)