diff options
| author | Tom Christie | 2013-05-10 21:57:05 +0100 |
|---|---|---|
| committer | Tom Christie | 2013-05-10 21:57:05 +0100 |
| commit | 773a92eab3ac4b635511483ef906b3b8de9dedc9 (patch) | |
| tree | c63c2728865337dc6824cd1efe70e0276c2f9d2b /rest_framework/tests/pagination.py | |
| parent | fd84cf7f10bf703c5daae4a5f6a7dee0c22471dd (diff) | |
| download | django-rest-framework-773a92eab3ac4b635511483ef906b3b8de9dedc9.tar.bz2 | |
Move models into test modules, out of models module
Diffstat (limited to 'rest_framework/tests/pagination.py')
| -rw-r--r-- | rest_framework/tests/pagination.py | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/rest_framework/tests/pagination.py b/rest_framework/tests/pagination.py index 6b8ef02f..894d53d6 100644 --- a/rest_framework/tests/pagination.py +++ b/rest_framework/tests/pagination.py @@ -1,18 +1,24 @@ from __future__ import unicode_literals import datetime from decimal import Decimal -import django +from django.db import models from django.core.paginator import Paginator from django.test import TestCase from django.test.client import RequestFactory from django.utils import unittest from rest_framework import generics, status, pagination, filters, serializers from rest_framework.compat import django_filters -from rest_framework.tests.models import BasicModel, FilterableItem +from rest_framework.tests.models import BasicModel factory = RequestFactory() +class FilterableItem(models.Model): + text = models.CharField(max_length=100) + decimal = models.DecimalField(max_digits=4, decimal_places=2) + date = models.DateField() + + class RootView(generics.ListCreateAPIView): """ Example description for OPTIONS. |
