Ticket #24636: 24636-test.diff

File 24636-test.diff, 1.1 KB (added by Tim Graham, 9 years ago)
  • tests/model_fields/tests.py

    diff --git a/tests/model_fields/tests.py b/tests/model_fields/tests.py
    index 6b63b8f..9a86353 100644
    a b from django.utils.functional import lazy  
    2323
    2424from .models import (
    2525    Bar, BigD, BigIntegerModel, BigS, BooleanModel, DataModel, DateTimeModel,
    26     Document, FksToBooleans, FkToChar, FloatModel, Foo, GenericIPAddress,
    27     IntegerModel, NullBooleanModel, PositiveIntegerModel,
     26    DecimalLessThanOne, Document, FksToBooleans, FkToChar, FloatModel, Foo,
     27    GenericIPAddress, IntegerModel, NullBooleanModel, PositiveIntegerModel,
    2828    PositiveSmallIntegerModel, Post, PrimaryKeyCharModel, RenamedField,
    2929    SmallIntegerModel, VerboseNameField, Whiz, WhizIter, WhizIterEmpty,
    3030)
    class DecimalFieldTests(test.TestCase):  
    163163        # This should not crash. That counts as a win for our purposes.
    164164        Foo.objects.filter(d__gte=100000000000)
    165165
     166    def test_max_digits_equals_decimal_places(self):
     167        a = DecimalLessThanOne(d=1)
     168        a.full_clean()
     169        a.save()
     170
    166171
    167172class ForeignKeyTests(test.TestCase):
    168173    def test_callable_default(self):
Back to Top