remove unnecessary sys.path manipulation in tests
This commit is contained in:
parent
6b2cebb07b
commit
bc6c84c408
@ -3,8 +3,6 @@ This test has been put into a module. This is because it tests warnings that
|
|||||||
only get triggered on first hit. This way we can ensure its imported into the
|
only get triggered on first hit. This way we can ensure its imported into the
|
||||||
top level and called first by the test suite.
|
top level and called first by the test suite.
|
||||||
"""
|
"""
|
||||||
import sys
|
|
||||||
sys.path[0:0] = [""]
|
|
||||||
import unittest
|
import unittest
|
||||||
import warnings
|
import warnings
|
||||||
|
|
||||||
|
@ -1,5 +1,3 @@
|
|||||||
import sys
|
|
||||||
sys.path[0:0] = [""]
|
|
||||||
import unittest
|
import unittest
|
||||||
|
|
||||||
from class_methods import *
|
from class_methods import *
|
||||||
|
@ -1,6 +1,4 @@
|
|||||||
# -*- coding: utf-8 -*-
|
# -*- coding: utf-8 -*-
|
||||||
import sys
|
|
||||||
sys.path[0:0] = [""]
|
|
||||||
import unittest
|
import unittest
|
||||||
|
|
||||||
from mongoengine import *
|
from mongoengine import *
|
||||||
|
@ -1,6 +1,4 @@
|
|||||||
# -*- coding: utf-8 -*-
|
# -*- coding: utf-8 -*-
|
||||||
import sys
|
|
||||||
sys.path[0:0] = [""]
|
|
||||||
import unittest
|
import unittest
|
||||||
|
|
||||||
from bson import SON
|
from bson import SON
|
||||||
|
@ -1,6 +1,4 @@
|
|||||||
import unittest
|
import unittest
|
||||||
import sys
|
|
||||||
sys.path[0:0] = [""]
|
|
||||||
|
|
||||||
from mongoengine import *
|
from mongoengine import *
|
||||||
from mongoengine.connection import get_db
|
from mongoengine.connection import get_db
|
||||||
|
@ -1,6 +1,4 @@
|
|||||||
# -*- coding: utf-8 -*-
|
# -*- coding: utf-8 -*-
|
||||||
import sys
|
|
||||||
sys.path[0:0] = [""]
|
|
||||||
import unittest
|
import unittest
|
||||||
import warnings
|
import warnings
|
||||||
|
|
||||||
|
@ -1,6 +1,3 @@
|
|||||||
import sys
|
|
||||||
sys.path[0:0] = [""]
|
|
||||||
|
|
||||||
import unittest
|
import unittest
|
||||||
import uuid
|
import uuid
|
||||||
|
|
||||||
|
@ -1,7 +1,4 @@
|
|||||||
# -*- coding: utf-8 -*-
|
# -*- coding: utf-8 -*-
|
||||||
import sys
|
|
||||||
sys.path[0:0] = [""]
|
|
||||||
|
|
||||||
import unittest
|
import unittest
|
||||||
from datetime import datetime
|
from datetime import datetime
|
||||||
|
|
||||||
|
@ -1,7 +1,4 @@
|
|||||||
# -*- coding: utf-8 -*-
|
# -*- coding: utf-8 -*-
|
||||||
import sys
|
|
||||||
sys.path[0:0] = [""]
|
|
||||||
|
|
||||||
import copy
|
import copy
|
||||||
import os
|
import os
|
||||||
import unittest
|
import unittest
|
||||||
|
@ -1,7 +1,4 @@
|
|||||||
# -*- coding: utf-8 -*-
|
# -*- coding: utf-8 -*-
|
||||||
import sys
|
|
||||||
sys.path[0:0] = [""]
|
|
||||||
|
|
||||||
import unittest
|
import unittest
|
||||||
|
|
||||||
from mongoengine import *
|
from mongoengine import *
|
||||||
|
@ -1,6 +1,3 @@
|
|||||||
import sys
|
|
||||||
sys.path[0:0] = [""]
|
|
||||||
|
|
||||||
import unittest
|
import unittest
|
||||||
|
|
||||||
from mongoengine import *
|
from mongoengine import *
|
||||||
|
@ -1,9 +1,5 @@
|
|||||||
import sys
|
|
||||||
|
|
||||||
sys.path[0:0] = [""]
|
|
||||||
|
|
||||||
import unittest
|
|
||||||
from datetime import datetime, timedelta
|
from datetime import datetime, timedelta
|
||||||
|
import unittest
|
||||||
|
|
||||||
from pymongo.errors import OperationFailure
|
from pymongo.errors import OperationFailure
|
||||||
from mongoengine import *
|
from mongoengine import *
|
||||||
|
@ -1,6 +1,3 @@
|
|||||||
import sys
|
|
||||||
sys.path[0:0] = [""]
|
|
||||||
|
|
||||||
import unittest
|
import unittest
|
||||||
|
|
||||||
from mongoengine import connect, Document, IntField
|
from mongoengine import connect, Document, IntField
|
||||||
@ -99,4 +96,4 @@ class FindAndModifyTest(unittest.TestCase):
|
|||||||
|
|
||||||
|
|
||||||
if __name__ == '__main__':
|
if __name__ == '__main__':
|
||||||
unittest.main()
|
unittest.main()
|
||||||
|
@ -1,9 +1,6 @@
|
|||||||
import sys
|
|
||||||
import datetime
|
import datetime
|
||||||
from pymongo.errors import OperationFailure
|
from pymongo.errors import OperationFailure
|
||||||
|
|
||||||
sys.path[0:0] = [""]
|
|
||||||
|
|
||||||
try:
|
try:
|
||||||
import unittest2 as unittest
|
import unittest2 as unittest
|
||||||
except ImportError:
|
except ImportError:
|
||||||
|
@ -1,5 +1,3 @@
|
|||||||
import sys
|
|
||||||
sys.path[0:0] = [""]
|
|
||||||
import unittest
|
import unittest
|
||||||
|
|
||||||
from mongoengine import *
|
from mongoengine import *
|
||||||
|
@ -1,6 +1,4 @@
|
|||||||
# -*- coding: utf-8 -*-
|
# -*- coding: utf-8 -*-
|
||||||
import sys
|
|
||||||
sys.path[0:0] = [""]
|
|
||||||
import unittest
|
import unittest
|
||||||
|
|
||||||
from bson import DBRef, ObjectId
|
from bson import DBRef, ObjectId
|
||||||
|
@ -1,6 +1,3 @@
|
|||||||
import sys
|
|
||||||
|
|
||||||
sys.path[0:0] = [""]
|
|
||||||
import unittest
|
import unittest
|
||||||
|
|
||||||
from pymongo import ReadPreference
|
from pymongo import ReadPreference
|
||||||
|
@ -1,6 +1,4 @@
|
|||||||
# -*- coding: utf-8 -*-
|
# -*- coding: utf-8 -*-
|
||||||
import sys
|
|
||||||
sys.path[0:0] = [""]
|
|
||||||
import unittest
|
import unittest
|
||||||
|
|
||||||
from mongoengine import *
|
from mongoengine import *
|
||||||
|
Loading…
x
Reference in New Issue
Block a user