{ "info": { "author": "David Jonas, Andre Goncalves", "author_email": "david@intk.com, andre@intk.com", "bugtrack_url": null, "classifiers": [ "Framework :: Plone", "Intended Audience :: Developers", "License :: OSI Approved :: GNU General Public License (GPL)" ], "description": ".. contents::\n\n.. Note!\n -----\n Update the following URLs to point to your:\n\n - code repository\n - bug tracker\n - questions/comments feedback mail\n (do not set a real mail, to avoid spams)\n\n Or remove it if not used.\n\n- Code repository: http://svn.somewhere.com/...\n- Questions and comments to somemailing_list\n- Report bugs at http://bug.somewhere.com/..\n\n\nChange history\n**************\n\nChangelog\n=========\n\n0.5 (2015-10-13)\n----------------\n\n- Added social information for person media type [andreg]\n\n0.1 (xxxx-xx-xx)\n----------------\n\n- Created recipe with ZopeSkel\n [David Jonas]\n\nDetailed Documentation\n**********************\n\nIntroduction\n============\n\nThis is a full-blown functional test. The emphasis here is on testing what\nthe user may input and see, and the system is largely tested as a black box.\nWe use PloneTestCase to set up this test as well, so we have a full Plone site\nto play with. We *can* inspect the state of the portal, e.g. using \nself.portal and self.folder, but it is often frowned upon since you are not\ntreating the system as a black box. Also, if you, for example, log in or set\nroles using calls like self.setRoles(), these are not reflected in the test\nbrowser, which runs as a separate session.\n\nBeing a doctest, we can tell a story here.\n\nFirst, we must perform some setup. We use the testbrowser that is shipped\nwith Five, as this provides proper Zope 2 integration. Most of the \ndocumentation, though, is in the underlying zope.testbrower package.\n\n >>> from Products.Five.testbrowser import Browser\n >>> browser = Browser()\n >>> portal_url = self.portal.absolute_url()\n\nThe following is useful when writing and debugging testbrowser tests. It lets\nus see all error messages in the error_log.\n\n >>> self.portal.error_log._ignored_exceptions = ()\n\nWith that in place, we can go to the portal front page and log in. We will\ndo this using the default user from PloneTestCase:\n\n >>> from Products.PloneTestCase.setup import portal_owner, default_password\n\nBecause add-on themes or products may remove or hide the login portlet, this test will use the login form that comes with plone. \n\n >>> browser.open(portal_url + '/login_form')\n >>> browser.getControl(name='__ac_name').value = portal_owner\n >>> browser.getControl(name='__ac_password').value = default_password\n >>> browser.getControl(name='submit').click()\n\nHere, we set the value of the fields on the login form and then simulate a\nsubmit click. We then ensure that we get the friendly logged-in message:\n\n >>> \"You are now logged in\" in browser.contents\n True\n\nFinally, let's return to the front page of our site before continuing\n\n >>> browser.open(portal_url)\n\n-*- extra stuff goes here -*-\nThe Media Person content type\n===============================\n\nIn this section we are tesing the Media Person content type by performing\nbasic operations like adding, updadating and deleting Media Person content\nitems.\n\nAdding a new Media Person content item\n--------------------------------\n\nWe use the 'Add new' menu to add a new content item.\n\n >>> browser.getLink('Add new').click()\n\nThen we select the type of item we want to add. In this case we select\n'Media Person' and click the 'Add' button to get to the add form.\n\n >>> browser.getControl('Media Person').click()\n >>> browser.getControl(name='form.button.Add').click()\n >>> 'Media Person' in browser.contents\n True\n\nNow we fill the form and submit it.\n\n >>> browser.getControl(name='title').value = 'Media Person Sample'\n >>> browser.getControl('Save').click()\n >>> 'Changes saved' in browser.contents\n True\n\nAnd we are done! We added a new 'Media Person' content item to the portal.\n\nUpdating an existing Media Person content item\n---------------------------------------\n\nLet's click on the 'edit' tab and update the object attribute values.\n\n >>> browser.getLink('Edit').click()\n >>> browser.getControl(name='title').value = 'New Media Person Sample'\n >>> browser.getControl('Save').click()\n\nWe check that the changes were applied.\n\n >>> 'Changes saved' in browser.contents\n True\n >>> 'New Media Person Sample' in browser.contents\n True\n\nRemoving a/an Media Person content item\n--------------------------------\n\nIf we go to the home page, we can see a tab with the 'New Media Person\nSample' title in the global navigation tabs.\n\n >>> browser.open(portal_url)\n >>> 'New Media Person Sample' in browser.contents\n True\n\nNow we are going to delete the 'New Media Person Sample' object. First we\ngo to the contents tab and select the 'New Media Person Sample' for\ndeletion.\n\n >>> browser.getLink('Contents').click()\n >>> browser.getControl('New Media Person Sample').click()\n\nWe click on the 'Delete' button.\n\n >>> browser.getControl('Delete').click()\n >>> 'Item(s) deleted' in browser.contents\n True\n\nSo, if we go back to the home page, there is no longer a 'New Media Person\nSample' tab.\n\n >>> browser.open(portal_url)\n >>> 'New Media Person Sample' in browser.contents\n False\n\nAdding a new Media Person content item as contributor\n------------------------------------------------\n\nNot only site managers are allowed to add Media Person content items, but\nalso site contributors.\n\nLet's logout and then login as 'contributor', a portal member that has the\ncontributor role assigned.\n\n >>> browser.getLink('Log out').click()\n >>> browser.open(portal_url + '/login_form')\n >>> browser.getControl(name='__ac_name').value = 'contributor'\n >>> browser.getControl(name='__ac_password').value = default_password\n >>> browser.getControl(name='submit').click()\n >>> browser.open(portal_url)\n\nWe use the 'Add new' menu to add a new content item.\n\n >>> browser.getLink('Add new').click()\n\nWe select 'Media Person' and click the 'Add' button to get to the add form.\n\n >>> browser.getControl('Media Person').click()\n >>> browser.getControl(name='form.button.Add').click()\n >>> 'Media Person' in browser.contents\n True\n\nNow we fill the form and submit it.\n\n >>> browser.getControl(name='title').value = 'Media Person Sample'\n >>> browser.getControl('Save').click()\n >>> 'Changes saved' in browser.contents\n True\n\nDone! We added a new Media Person content item logged in as contributor.\n\nFinally, let's login back as manager.\n\n >>> browser.getLink('Log out').click()\n >>> browser.open(portal_url + '/login_form')\n >>> browser.getControl(name='__ac_name').value = portal_owner\n >>> browser.getControl(name='__ac_password').value = default_password\n >>> browser.getControl(name='submit').click()\n >>> browser.open(portal_url)\n\n\n\n\nContributors\n************\n\nDavid Jonas, Author\nAndre Goncalves\n\n\nDownload\n********", "description_content_type": null, "docs_url": null, "download_url": "UNKNOWN", "downloads": { "last_day": -1, "last_month": -1, "last_week": -1 }, "home_page": "http://svn.plone.org/svn/collective/", "keywords": "type folderish person", "license": "GPL", "maintainer": null, "maintainer_email": null, "name": "Products.mediaPersons", "package_url": "https://pypi.org/project/Products.mediaPersons/", "platform": "UNKNOWN", "project_url": "https://pypi.org/project/Products.mediaPersons/", "project_urls": { "Download": "UNKNOWN", "Homepage": "http://svn.plone.org/svn/collective/" }, "release_url": "https://pypi.org/project/Products.mediaPersons/0.64/", "requires_dist": null, "requires_python": null, "summary": "Person type with folderish behaviour to store related media.", "version": "0.64" }, "last_serial": 1290119, "releases": { "0.5": [ { "comment_text": "", "digests": { "md5": "a2ffd0de1cc5c66115c7079f2f2f8628", "sha256": "d6d9f6123699342efa5d808beeed427323b4aff319aadc62a555a68100f97116" }, "downloads": -1, "filename": "Products.mediaPersons-0.5.tar.gz", "has_sig": false, "md5_digest": "a2ffd0de1cc5c66115c7079f2f2f8628", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 21635, "upload_time": "2014-10-13T14:40:22", "url": "https://files.pythonhosted.org/packages/6c/02/6e725b9c6177fe8fcd0252aa2723d34ca70f0a4162a0d32ffe06e0a0996f/Products.mediaPersons-0.5.tar.gz" } ], "0.6": [ { "comment_text": "", "digests": { "md5": "fe76b372648523e20d14b70dee7a9f77", "sha256": "d8d307e8824289a759f2dcf6d5b6c797d506814431d50dd7d97d0992f03b8422" }, "downloads": -1, "filename": "Products.mediaPersons-0.6.tar.gz", "has_sig": false, "md5_digest": "fe76b372648523e20d14b70dee7a9f77", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 21614, "upload_time": "2014-10-13T15:00:05", "url": "https://files.pythonhosted.org/packages/a2/c9/153b0c16827b6a6b7466a965a66336d40a3afe781b209c1fa13b8b87ed56/Products.mediaPersons-0.6.tar.gz" } ], "0.61": [ { "comment_text": "", "digests": { "md5": "ae7edc4fc587aba32ab2d13ebceaa277", "sha256": "28a0aea97750aa225c66c404624051760e0c46f0f4324e6d320a5fec344fbea3" }, "downloads": -1, "filename": "Products.mediaPersons-0.61.tar.gz", "has_sig": false, "md5_digest": "ae7edc4fc587aba32ab2d13ebceaa277", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 21600, "upload_time": "2014-10-13T21:15:13", "url": "https://files.pythonhosted.org/packages/14/3d/17752b5a206587f1e6f83d4163588785c21c89422eaa60b81c6cc53dc236/Products.mediaPersons-0.61.tar.gz" } ], "0.62": [ { "comment_text": "", "digests": { "md5": "2cd3286015e34bebf753310437e5cbe7", "sha256": "f89a2f3eefc3e3d301e38e571b96c6c203ec63b609cbeca1a0de2477dc634218" }, "downloads": -1, "filename": "Products.mediaPersons-0.62.tar.gz", "has_sig": false, "md5_digest": "2cd3286015e34bebf753310437e5cbe7", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 21696, "upload_time": "2014-10-16T13:23:44", "url": "https://files.pythonhosted.org/packages/40/ea/f2f2caee32e63a4dea1cc26e36880100107926d0a36303cc43c8fae56279/Products.mediaPersons-0.62.tar.gz" } ], "0.63": [ { "comment_text": "", "digests": { "md5": "872858603a85dc834ee80156c3b1dfa6", "sha256": "f2415629b3723a2ff235a0721c1f5ecdfaf0c7503103d3892305f98f7af4064e" }, "downloads": -1, "filename": "Products.mediaPersons-0.63.tar.gz", "has_sig": false, "md5_digest": "872858603a85dc834ee80156c3b1dfa6", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 21667, "upload_time": "2014-10-17T16:16:39", "url": "https://files.pythonhosted.org/packages/a8/7d/516300feaf5980d8922528a3afb75c886224e9c1617a2f45c05b3d7ddbdc/Products.mediaPersons-0.63.tar.gz" } ], "0.64": [ { "comment_text": "", "digests": { "md5": "838283005227b2299d1d8e06a234f21f", "sha256": "b3f981fca2d82868300c23786b6229e23204565a1f1a4c15fec2941207ebce4c" }, "downloads": -1, "filename": "Products.mediaPersons-0.64.tar.gz", "has_sig": false, "md5_digest": "838283005227b2299d1d8e06a234f21f", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 21679, "upload_time": "2014-10-31T16:33:13", "url": "https://files.pythonhosted.org/packages/6c/5a/ce1882e0a54223f7f46f1456b5dcc96ce47cde8d5fb46d57815cef3413d9/Products.mediaPersons-0.64.tar.gz" } ] }, "urls": [ { "comment_text": "", "digests": { "md5": "838283005227b2299d1d8e06a234f21f", "sha256": "b3f981fca2d82868300c23786b6229e23204565a1f1a4c15fec2941207ebce4c" }, "downloads": -1, "filename": "Products.mediaPersons-0.64.tar.gz", "has_sig": false, "md5_digest": "838283005227b2299d1d8e06a234f21f", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 21679, "upload_time": "2014-10-31T16:33:13", "url": "https://files.pythonhosted.org/packages/6c/5a/ce1882e0a54223f7f46f1456b5dcc96ce47cde8d5fb46d57815cef3413d9/Products.mediaPersons-0.64.tar.gz" } ] }