Skip to content

Commit 9e72c57

Browse files
feat: ✨ add dependencies to core cusy packages
1 parent 6a5faa8 commit 9e72c57

File tree

8 files changed

+76
-7
lines changed

8 files changed

+76
-7
lines changed

.gitignore

+1
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@
99
.venv/
1010
bin/
1111
buildout-cache/
12+
checkouts/
1213
develop-eggs/
1314
eggs/
1415
htmlcov/

README.rst

+15
Original file line numberDiff line numberDiff line change
@@ -35,6 +35,21 @@ The main policy package to install the Cusy CMS.
3535
Features
3636
--------
3737

38+
Dependencies
39+
------------
40+
41+
``cusy.cms`` depends on and installs the following add-ons:
42+
43+
- `cusy.exportimport <https://github.com/cusyio/cusy.exportimport>`_:
44+
Extensions and patches for collective.exportimport.
45+
- `cusy.restapi.easyform <https://github.com/cusyio/cusy.restapi.easyform>`_:
46+
EasyForm integration for plone.restapi.
47+
- `cusy.restapi.info <https://github.com/cusyio/cusy.restapi.info>`_:
48+
Site and content info for plone.restapi.
49+
- `cusy.restapi.patches <https://github.com/cusyio/cusy.restapi.patches>`_:
50+
Patches and fixes for plone.restapi which are not yet released.
51+
52+
3853

3954
Installation
4055
------------

base.cfg

+11
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,9 @@ parts =
2020

2121
develop = .
2222

23+
auto-checkout = *
24+
sources-dir = checkouts
25+
2326

2427
[instance]
2528
recipe = plone.recipe.zope2instance
@@ -106,6 +109,14 @@ scripts =
106109
zopepy
107110
plone-compile-resources
108111

112+
113+
[sources]
114+
cusy.exportimport = git https://github.com/cusyio/cusy.exportimport.git
115+
cusy.restapi.easyform = git https://github.com/cusyio/cusy.restapi.easyform.git
116+
cusy.restapi.info = git https://github.com/cusyio/cusy.restapi.info.git
117+
cusy.restapi.patches = git https://github.com/cusyio/cusy.restapi.patches.git
118+
119+
109120
[versions]
110121
# Don't use a released version of cusy.cms
111122
cusy.cms =

setup.py

+4
Original file line numberDiff line numberDiff line change
@@ -49,6 +49,10 @@
4949
python_requires=">=3.6",
5050
install_requires=[
5151
"setuptools",
52+
"cusy.exportimport",
53+
"cusy.restapi.easyform",
54+
"cusy.restapi.info",
55+
"cusy.restapi.patches",
5256
],
5357
extras_require={
5458
"test": [

src/cusy/cms/configure.zcml

+5
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,11 @@
66

77
<i18n:registerTranslations directory="locales" />
88

9+
<include package="cusy.exportimport" />
10+
<include package="cusy.restapi.easyform" />
11+
<include package="cusy.restapi.info" />
12+
<include package="cusy.restapi.patches" />
13+
914
<include file="permissions.zcml" />
1015
<include file="profiles.zcml" />
1116
<include package=".browser" />

src/cusy/cms/profiles/default/metadata.xml

+4-1
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,9 @@
22
<metadata>
33
<version>1000</version>
44
<dependencies>
5-
<!--<dependency>profile-plone.app.dexterity:default</dependency>-->
5+
<dependency>profile-cusy.exportimport:default</dependency>
6+
<dependency>profile-cusy.restapi.easyform:default</dependency>
7+
<dependency>profile-cusy.restapi.info:default</dependency>
8+
<dependency>profile-cusy.restapi.patches:default</dependency>
69
</dependencies>
710
</metadata>

src/cusy/cms/tests/test_setup.py

+22-6
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515

1616

1717
class TestSetup(unittest.TestCase):
18-
"""Test that cusy.cms is properly installed."""
18+
"""Validate that `cusy.cms` is properly installed."""
1919

2020
layer = INTEGRATION_TESTING
2121

@@ -28,20 +28,36 @@ def setUp(self):
2828
self.installer = api.portal.get_tool("portal_quickinstaller")
2929

3030
def test_product_installed(self):
31-
"""Test if cusy.cms is installed."""
31+
"""Validate that `cusy.cms` is installed."""
3232
self.assertTrue(self.installer.isProductInstalled("cusy.cms"))
3333

3434
def test_browserlayer(self):
35-
"""Test that ICusyCmsLayer is registered."""
35+
"""Validate that the browser layer is registered."""
3636
from cusy.cms.interfaces import ICusyCmsLayer
3737
from plone.browserlayer import utils
3838

3939
self.assertIn(ICusyCmsLayer, utils.registered_layers())
4040

41+
def test_cusy_exportimport_installed(self):
42+
"""Validate that `cusy.exportimport` is installed."""
43+
self.assertTrue(self.installer.isProductInstalled("cusy.exportimport"))
44+
45+
def test_cusy_restapi_easyform_installed(self):
46+
"""Validate that `cusy.restapi.easyform` is installed."""
47+
self.assertTrue(self.installer.isProductInstalled("cusy.restapi.easyform"))
48+
49+
def test_cusy_restapi_info_installed(self):
50+
"""Validate that `cusy.restapi.info` is installed."""
51+
self.assertTrue(self.installer.isProductInstalled("cusy.restapi.info"))
52+
53+
def test_cusy_restapi_patches_installed(self):
54+
"""Validate that `cusy.restapi.patches` is installed."""
55+
self.assertTrue(self.installer.isProductInstalled("cusy.restapi.patches"))
56+
4157

4258
class TestUninstall(unittest.TestCase):
4359

44-
layer = CUSY_CMS_INTEGRATION_TESTING
60+
layer = INTEGRATION_TESTING
4561

4662
def setUp(self):
4763
self.portal = self.layer["portal"]
@@ -55,11 +71,11 @@ def setUp(self):
5571
setRoles(self.portal, TEST_USER_ID, roles_before)
5672

5773
def test_product_uninstalled(self):
58-
"""Test if cusy.cms is cleanly uninstalled."""
74+
"""Validate that `cusy.cms` is cleanly uninstalled."""
5975
self.assertFalse(self.installer.isProductInstalled("cusy.cms"))
6076

6177
def test_browserlayer_removed(self):
62-
"""Test that ICusyCmsLayer is removed."""
78+
"""Validate that the browser layer is removed."""
6379
from cusy.cms.interfaces import ICusyCmsLayer
6480
from plone.browserlayer import utils
6581

test_plone52.cfg

+14
Original file line numberDiff line numberDiff line change
@@ -15,3 +15,17 @@ collective.recipe.vscode = >=0.1.6
1515
configparser = 4.0.2
1616
createcoverage = 1.5
1717
zipp = 1.2.0
18+
19+
# Added by buildout at 2021-07-12 16:22:45.710215
20+
21+
# Required by:
22+
# cusy.restapi.easyform==1.0.0.dev0
23+
collective.easyform = 3.0.5
24+
25+
# Required by:
26+
# cusy.exportimport==1.0.0.dev0
27+
collective.exportimport = 1.0
28+
29+
# Required by:
30+
# collective.exportimport==1.0
31+
hurry.filesize = 0.9

0 commit comments

Comments
 (0)