Merge pull request #218 from metaodi/217-run-test-ckan23
Swap import statements to make sure `run_test` works on CKAN 2.3
This commit is contained in:
commit
aaa7dc9e4d
|
@ -1,9 +1,9 @@
|
|||
import factory
|
||||
import ckanext.harvest.model as harvest_model
|
||||
try:
|
||||
from ckan.tests.factories import _get_action_user_name
|
||||
except ImportError:
|
||||
from ckan.new_tests.factories import _get_action_user_name
|
||||
except ImportError:
|
||||
from ckan.tests.factories import _get_action_user_name
|
||||
from ckan.plugins import toolkit
|
||||
|
||||
|
||||
|
|
|
@ -7,9 +7,11 @@ from ckan.model import Package, Session
|
|||
from ckan.lib.helpers import url_for,json
|
||||
from ckan.lib.base import config
|
||||
|
||||
|
||||
from ckan.tests import CreateTestData
|
||||
#TODO: remove references to old tests
|
||||
try:
|
||||
from ckan.tests import CreateTestData
|
||||
except ImportError:
|
||||
from ckan.tests.legacy import CreateTestData
|
||||
try:
|
||||
from ckan.tests.functional.base import FunctionalTestCase
|
||||
except ImportError:
|
||||
|
|
Loading…
Reference in New Issue