def test_decimal_number_operations():
    """Test that decimal.Decimal values work with NumberVar operations."""
    dec_num = Var.create(decimal.Decimal("123.456"))
    assert isinstance(dec_num._var_value, decimal.Decimal)
    assert str(dec_num) == "123.456"

    result = dec_num + 10
    assert str(result) == "(123.456 + 10)"

    result = dec_num * 2
    assert str(result) == "(123.456 * 2)"

    result = dec_num / 2
    assert str(result) == "(123.456 / 2)"

    result = dec_num > 100
    assert str(result) == "(123.456 > 100)"

    result = dec_num < 200
    assert str(result) == "(123.456 < 200)"

    assert dec_num.json() == "123.456"
Test that decimal.Decimal values work with NumberVar operations.
tests/units/test_var.py