rename all test files so that they are prefixed by test_{orginal_filename}.py
This commit is contained in:
@@ -1,6 +0,0 @@
|
||||
from .transform import *
|
||||
from .field_list import *
|
||||
from .queryset import *
|
||||
from .visitor import *
|
||||
from .geo import *
|
||||
from .modify import *
|
||||
|
||||
@@ -3,10 +3,8 @@ import unittest
|
||||
from mongoengine import *
|
||||
from mongoengine.queryset import QueryFieldList
|
||||
|
||||
__all__ = ("QueryFieldListTest", "OnlyExcludeAllTest")
|
||||
|
||||
|
||||
class QueryFieldListTest(unittest.TestCase):
|
||||
class TestQueryFieldList(unittest.TestCase):
|
||||
def test_empty(self):
|
||||
q = QueryFieldList()
|
||||
self.assertFalse(q)
|
||||
@@ -66,7 +64,7 @@ class QueryFieldListTest(unittest.TestCase):
|
||||
self.assertEqual(q.as_dict(), {"a": {"$slice": 5}})
|
||||
|
||||
|
||||
class OnlyExcludeAllTest(unittest.TestCase):
|
||||
class TestOnlyExcludeAll(unittest.TestCase):
|
||||
def setUp(self):
|
||||
connect(db="mongoenginetest")
|
||||
|
||||
@@ -6,10 +6,7 @@ from mongoengine import *
|
||||
from tests.utils import MongoDBTestCase
|
||||
|
||||
|
||||
__all__ = ("GeoQueriesTest",)
|
||||
|
||||
|
||||
class GeoQueriesTest(MongoDBTestCase):
|
||||
class TestGeoQueries(MongoDBTestCase):
|
||||
def _create_event_data(self, point_field_class=GeoPointField):
|
||||
"""Create some sample data re-used in many of the tests below."""
|
||||
|
||||
@@ -41,7 +41,7 @@ def get_key_compat(mongo_ver):
|
||||
return ORDER_BY_KEY, CMD_QUERY_KEY
|
||||
|
||||
|
||||
class QuerySetTest(unittest.TestCase):
|
||||
class TestQueryset(unittest.TestCase):
|
||||
def setUp(self):
|
||||
connect(db="mongoenginetest")
|
||||
connect(db="mongoenginetest2", alias="test2")
|
||||
Reference in New Issue
Block a user