Repository: nephila/djangocms-installer
Pull request #296 (2016-11-30 04:11:23)

Switch to final core plugins setup


Patch:
diff --git a/HISTORY.rst b/HISTORY.rst
index 8cc0355..6b2bf00 100644
--- a/HISTORY.rst
+++ b/HISTORY.rst
@@ -3,6 +3,11 @@
 History
 -------
 
+1.0.0 (unreleased)
+++++++++++++++++++
+
+* Dropped cmsplugin-filer in favor of core plugins which now use filer
+
 0.9.3 (2016-11-16)
 ++++++++++++++++++
 
diff --git a/djangocms_installer/config/data.py b/djangocms_installer/config/data.py
index ed0283e..7c7c3ad 100644
--- a/djangocms_installer/config/data.py
+++ b/djangocms_installer/config/data.py
@@ -103,6 +103,8 @@ REQUIREMENTS = {
         'djangocms-snippet>=1.9,<2.0',
         'djangocms-video>=1.1,<2.0',
         'djangocms-column>=1.6,<1.7',
+        'djangocms-file>=1.0,<1.1',
+        'djangocms-picture>=0.2.0,<0.3',
     ],
     'plugins-3.3': [
         'djangocms-text-ckeditor>=3.2.1',
@@ -112,6 +114,8 @@ REQUIREMENTS = {
         'djangocms-snippet>=1.9',
         'djangocms-video>=2.0',
         'djangocms-column>=1.6',
+        'djangocms-file>=1.0,<1.1',
+        'djangocms-picture>=0.2.0,<0.3',
     ],
     'plugins-3.4': [
         'djangocms-text-ckeditor>=3.2.1',
@@ -121,31 +125,28 @@ REQUIREMENTS = {
         'djangocms-snippet>=1.9',
         'djangocms-video>=2.0',
         'djangocms-column>=1.6',
+        'djangocms-file>=2.0,<3.0',
+        'djangocms-picture>=2.0,<3.0',
     ],
     'plugins-master': [
         'https://github.com/divio/djangocms-text-ckeditor/archive/master.zip?{bust}'
         ''.format(**bust),
+        'https://github.com/divio/djangocms-file/archive/master.zip?{bust}'.format(**bust),
         'https://github.com/divio/djangocms-link/archive/master.zip?{bust}'.format(**bust),
         'https://github.com/divio/djangocms-style/archive/master.zip?{bust}'.format(**bust),
         'https://github.com/divio/djangocms-googlemap/archive/master.zip?{bust}'.format(**bust),
         'https://github.com/divio/djangocms-snippet/archive/master.zip?{bust}'.format(**bust),
+        'https://github.com/divio/djangocms-picture/archive/master.zip?{bust}'.format(**bust),
         'https://github.com/divio/djangocms-video/archive/master.zip?{bust}'.format(**bust),
         'https://github.com/divio/djangocms-column/archive/master.zip?{bust}'.format(**bust),
     ],
     'plugins-basic': [
-        'djangocms-file>=1.0,<1.1',
-        'djangocms-picture>=0.2.0,<0.3',
-        'djangocms-teaser>=0.2.0,<0.3',
     ],
     'plugins-basic-master': [
-        'https://github.com/divio/djangocms-file/archive/master.zip?{bust}'.format(**bust),
-        'https://github.com/divio/djangocms-picture/archive/master.zip?{bust}'.format(**bust),
-        'https://github.com/divio/djangocms-teaser/archive/master.zip?{bust}'.format(**bust),
     ],
     'filer': [
         'easy_thumbnails',
         'django-filer>=1.2',
-        'cmsplugin-filer>=1.1',
     ],
 }
 
@@ -170,9 +171,8 @@ PLUGIN_LIST_TEXT = """
 djangocms installer will install and configure the following plugins:
  * djangocms-text-ckeditor (Text plugin)
  * djangocms-link (Link plugin)
- * cmsplugin_filer_file (File plugin, replaces djangocms-file)
- * cmsplugin_filer_folder (Folder plugin)
- * cmsplugin_filer_image (Image plugin, replaces djangocms-picture)
+ * djangocms-file (File plugin)
+ * djangocms-picture (Image plugin)
  * djangocms-style (Style plugin)
  * djangocms-snippet (Snippet plugin)
  * djangocms-googlemap (GoogleMap plugin)
diff --git a/djangocms_installer/config/settings.py b/djangocms_installer/config/settings.py
index 25c0631..afe7011 100644
--- a/djangocms_installer/config/settings.py
+++ b/djangocms_installer/config/settings.py
@@ -78,11 +78,9 @@ FILER_PLUGINS_3 = (
     'filer',
     'easy_thumbnails',
     'djangocms_column',
+    'djangocms_file',
     'djangocms_link',
-    'cmsplugin_filer_file',
-    'cmsplugin_filer_folder',
-    'cmsplugin_filer_image',
-    'cmsplugin_filer_utils',
+    'djangocms_picture',
     'djangocms_style',
     'djangocms_snippet',
     'djangocms_googlemap',


Test patch:
diff --git a/tests/config.py b/tests/config.py
index 3a80c0f..f1a6491 100644
--- a/tests/config.py
+++ b/tests/config.py
@@ -332,7 +332,8 @@ class TestConfig(BaseTestClass):
         self.assertTrue(conf_data.requirements.find('djangocms-text-ckeditor>=2.8.1') > -1)
         self.assertTrue(conf_data.requirements.find('djangocms-admin-style>=1.1.1') > -1)
         self.assertTrue(conf_data.requirements.find('django-filer') > -1)
-        self.assertTrue(conf_data.requirements.find('cmsplugin-filer') > -1)
+        self.assertTrue(conf_data.requirements.find('cmsplugin-filer') == -1)
+        self.assertTrue(conf_data.requirements.find('djangocms-file') > -1)
         self.assertTrue(conf_data.requirements.find('djangocms-text-ckeditor') > -1)
 
         conf_data = config.parse([
@@ -348,15 +349,16 @@ class TestConfig(BaseTestClass):
         self.assertTrue(conf_data.requirements.find('django-cms<3.5') > -1)
         self.assertTrue(conf_data.requirements.find('Django<1.9') > -1)
         self.assertFalse(conf_data.requirements.find('django-reversion') > -1)
+        self.assertTrue(conf_data.requirements.find('cmsplugin-filer') == -1)
         self.assertTrue(conf_data.requirements.find('djangocms-text-ckeditor>=3.2.1') > -1)
         self.assertTrue(conf_data.requirements.find('djangocms-admin-style>=1.2') > -1)
         self.assertTrue(conf_data.requirements.find('djangocms-column') > -1)
-        self.assertTrue(conf_data.requirements.find('djangocms-file') == -1)
+        self.assertTrue(conf_data.requirements.find('djangocms-file') > -1)
         self.assertTrue(conf_data.requirements.find('djangocms-flash') == -1)
         self.assertTrue(conf_data.requirements.find('djangocms-googlemap') > -1)
         self.assertTrue(conf_data.requirements.find('djangocms-inherit') == -1)
         self.assertTrue(conf_data.requirements.find('djangocms-link') > -1)
-        self.assertTrue(conf_data.requirements.find('djangocms-picture') == -1)
+        self.assertTrue(conf_data.requirements.find('djangocms-picture') > -1)
         self.assertTrue(conf_data.requirements.find('djangocms-style') > -1)
         self.assertTrue(conf_data.requirements.find('djangocms-teaser') == -1)
         self.assertTrue(conf_data.requirements.find('djangocms-video') > -1)
@@ -372,20 +374,21 @@ class TestConfig(BaseTestClass):
             '-p'+self.project_dir,
             'example_prj'])
 
+        print(conf_data.requirements)
         self.assertTrue(conf_data.requirements.find(config.data.DJANGOCMS_DEVELOP) > -1)
         self.assertTrue(conf_data.requirements.find('Django<1.9') > -1)
         self.assertFalse(conf_data.requirements.find('django-reversion') > -1)
         self.assertTrue(conf_data.requirements.find('djangocms-text-ckeditor') > -1)
         self.assertTrue(conf_data.requirements.find('djangocms-admin-style') > -1)
         self.assertTrue(conf_data.requirements.find('django-filer') > -1)
-        self.assertTrue(conf_data.requirements.find('cmsplugin-filer') > -1)
+        self.assertTrue(conf_data.requirements.find('cmsplugin-filer') == -1)
         self.assertTrue(conf_data.requirements.find('djangocms-column') > -1)
-        self.assertTrue(conf_data.requirements.find('djangocms-file') == -1)
+        self.assertTrue(conf_data.requirements.find('djangocms-file') > -1)
         self.assertTrue(conf_data.requirements.find('djangocms-flash') == -1)
         self.assertTrue(conf_data.requirements.find('djangocms-googlemap') > -1)
         self.assertTrue(conf_data.requirements.find('djangocms-inherit') == -1)
         self.assertTrue(conf_data.requirements.find('djangocms-link') > -1)
-        self.assertTrue(conf_data.requirements.find('djangocms-picture') == -1)
+        self.assertTrue(conf_data.requirements.find('djangocms-picture') > -1)
         self.assertTrue(conf_data.requirements.find('djangocms-style') > -1)
         self.assertTrue(conf_data.requirements.find('djangocms-teaser') == -1)
         self.assertTrue(conf_data.requirements.find('djangocms-video') > -1)
@@ -431,7 +434,6 @@ class TestConfig(BaseTestClass):
         self.assertTrue(conf_data.requirements.find('https://github.com/divio/djangocms-column') > -1)
         self.assertTrue(conf_data.requirements.find('https://github.com/divio/djangocms-admin-style') > -1)
         self.assertTrue(conf_data.requirements.find('https://github.com/divio/djangocms-text-ckeditor') > -1)
-
         self.assertTrue(conf_data.requirements.find('pytz') > -1)
 
         conf_data = config.parse([
diff --git a/tests/django.py b/tests/django.py
index 6786516..57d61c5 100644
--- a/tests/django.py
+++ b/tests/django.py
@@ -175,23 +175,23 @@ class TestDjango(IsolatedTestClass):
         self.assertEqual(project.settings.MEDIA_URL, '/media/')
 
         self.assertEqual(project.settings.TIME_ZONE, 'Europe/Moscow')
-        self.assertTrue('cmsplugin_filer_image' in project.settings.INSTALLED_APPS)
-        self.assertTrue('cmsplugin_filer_file' in project.settings.INSTALLED_APPS)
-        self.assertTrue('cmsplugin_filer_folder' in project.settings.INSTALLED_APPS)
+        self.assertTrue('cmsplugin_filer_image'not  in project.settings.INSTALLED_APPS)
+        self.assertTrue('cmsplugin_filer_file' not in project.settings.INSTALLED_APPS)
+        self.assertTrue('cmsplugin_filer_folder' not in project.settings.INSTALLED_APPS)
         self.assertTrue('cmsplugin_filer_link' not in project.settings.INSTALLED_APPS)
         self.assertTrue('cmsplugin_filer_teaser' not in project.settings.INSTALLED_APPS)
-        self.assertTrue('cmsplugin_filer_utils' in project.settings.INSTALLED_APPS)
+        self.assertTrue('cmsplugin_filer_utils' not in project.settings.INSTALLED_APPS)
         self.assertTrue('cmsplugin_filer_video' not in project.settings.INSTALLED_APPS)
         self.assertTrue('djangocms_text_ckeditor' in project.settings.INSTALLED_APPS)
         self.assertTrue('djangocms_admin_style' in project.settings.INSTALLED_APPS)
         self.assertTrue('filer' in project.settings.INSTALLED_APPS)
         self.assertTrue('djangocms_column' in project.settings.INSTALLED_APPS)
-        self.assertTrue('djangocms_file' not in project.settings.INSTALLED_APPS)
+        self.assertTrue('djangocms_file' in project.settings.INSTALLED_APPS)
         self.assertTrue('djangocms_flash' not in project.settings.INSTALLED_APPS)
         self.assertTrue('djangocms_googlemap' in project.settings.INSTALLED_APPS)
         self.assertTrue('djangocms_inherit' not in project.settings.INSTALLED_APPS)
         self.assertTrue('djangocms_link' in project.settings.INSTALLED_APPS)
-        self.assertTrue('djangocms_picture' not in project.settings.INSTALLED_APPS)
+        self.assertTrue('djangocms_picture' in project.settings.INSTALLED_APPS)
         self.assertTrue('djangocms_style' in project.settings.INSTALLED_APPS)
         self.assertTrue('djangocms_teaser' not in project.settings.INSTALLED_APPS)
         self.assertTrue('djangocms_video' in project.settings.INSTALLED_APPS)
@@ -388,22 +388,22 @@ class TestDjango(IsolatedTestClass):
         # checking for filer (optional) settings
         self.assertTrue('filer' in project.settings.INSTALLED_APPS)
         self.assertTrue('easy_thumbnails' in project.settings.INSTALLED_APPS)
-        self.assertTrue('cmsplugin_filer_image' in project.settings.INSTALLED_APPS)
-        self.assertTrue('cmsplugin_filer_file' in project.settings.INSTALLED_APPS)
-        self.assertTrue('cmsplugin_filer_folder' in project.settings.INSTALLED_APPS)
+        self.assertTrue('cmsplugin_filer_image' not in project.settings.INSTALLED_APPS)
+        self.assertTrue('cmsplugin_filer_file' not in project.settings.INSTALLED_APPS)
+        self.assertTrue('cmsplugin_filer_folder' not in project.settings.INSTALLED_APPS)
         self.assertTrue('cmsplugin_filer_link' not in project.settings.INSTALLED_APPS)
         self.assertTrue('cmsplugin_filer_teaser' not in project.settings.INSTALLED_APPS)
-        self.assertTrue('cmsplugin_filer_utils' in project.settings.INSTALLED_APPS)
+        self.assertTrue('cmsplugin_filer_utils' not in project.settings.INSTALLED_APPS)
         self.assertTrue('cmsplugin_filer_video' not in project.settings.INSTALLED_APPS)
         self.assertTrue('djangocms_text_ckeditor' in project.settings.INSTALLED_APPS)
         self.assertTrue('djangocms_admin_style' in project.settings.INSTALLED_APPS)
         self.assertTrue('filer' in project.settings.INSTALLED_APPS)
-        self.assertTrue('djangocms_file' not in project.settings.INSTALLED_APPS)
+        self.assertTrue('djangocms_file' in project.settings.INSTALLED_APPS)
         self.assertTrue('djangocms_flash' not in project.settings.INSTALLED_APPS)
         self.assertTrue('djangocms_googlemap' in project.settings.INSTALLED_APPS)
         self.assertTrue('djangocms_inherit' not in project.settings.INSTALLED_APPS)
         self.assertTrue('djangocms_link' in project.settings.INSTALLED_APPS)
-        self.assertTrue('djangocms_picture' not in project.settings.INSTALLED_APPS)
+        self.assertTrue('djangocms_picture' in project.settings.INSTALLED_APPS)
         self.assertTrue('djangocms_style' in project.settings.INSTALLED_APPS)
         self.assertTrue('djangocms_teaser' not in project.settings.INSTALLED_APPS)
         self.assertTrue('djangocms_video' in project.settings.INSTALLED_APPS)
diff --git a/tests/main.py b/tests/main.py
index 372e762..2d2b4c0 100644
--- a/tests/main.py
+++ b/tests/main.py
@@ -33,15 +33,15 @@ class TestMain(IsolatedTestClass):
         self.assertTrue(stdout.find('djangocms-text-ckeditor') > -1)
         self.assertTrue(stdout.find('djangocms-admin-style') > -1)
         self.assertTrue(stdout.find('djangocms-column') > -1)
-        self.assertTrue(stdout.find('djangocms-file') == -1)
+        self.assertTrue(stdout.find('djangocms-file') > -1)
         self.assertTrue(stdout.find('djangocms-flash') == -1)
         self.assertTrue(stdout.find('djangocms-googlemap') > -1)
         self.assertTrue(stdout.find('djangocms-inherit') == -1)
         self.assertTrue(stdout.find('djangocms-link') > -1)
-        self.assertTrue(stdout.find('djangocms-picture') == -1)
+        self.assertTrue(stdout.find('djangocms-picture') > -1)
         self.assertTrue(stdout.find('djangocms-style') > -1)
         self.assertTrue(stdout.find('djangocms-snippet') > -1)
-        self.assertTrue(stdout.find('cmsplugin-filer') > -1)
+        self.assertTrue(stdout.find('cmsplugin-filer') == -1)
         self.assertTrue(stdout.find('djangocms-teaser') == -1)
         self.assertTrue(stdout.find('djangocms-video') > -1)