Commit 80bfb0fe authored by Łukasz Nowak's avatar Łukasz Nowak

Dropped unused constraints.

parent a62e1d68
......@@ -437,87 +437,6 @@ class TestVifibPurchasePackingListLineConstraint(testVifibMixin):
self.assertFalse(consistency_message in getMessageList(line))
class TestVifibSoftwareReleaseConstraint(testVifibMixin):
def test_aggregate(self):
consistency_message_existence = 'One Software Product must be defined'
consistency_message_state = 'Software Product must be validated'
software_release = self.portal.software_release_module.newContent(
portal_type='Software Release')
software_release.publish()
self.assertTrue(consistency_message_existence in getMessageList(
software_release))
software_product = self.portal.software_product_module.newContent(
portal_type='Software Product')
software_release.setAggregate(software_product.getRelativeUrl())
self.assertFalse(consistency_message_existence in getMessageList(
software_release))
software_product_2 = self.portal.software_product_module.newContent(
portal_type='Software Product')
software_release.setAggregateList([software_product.getRelativeUrl(),
software_product_2.getRelativeUrl()])
self.assertTrue(consistency_message_existence in getMessageList(
software_release))
software_release.setAggregate(software_product.getRelativeUrl())
self.assertTrue(consistency_message_state in getMessageList(
software_release))
software_product.validate()
self.assertFalse(consistency_message_state in getMessageList(
software_release))
def test_contributor(self):
consistency_message_existence = 'One Contributor must be defined'
consistency_message_state = 'Contributor must be validated'
software_release = self.portal.software_release_module.newContent(
portal_type='Software Release')
self.assertTrue(consistency_message_existence in getMessageList(
software_release))
person = self.portal.person_module.newContent(
portal_type='Person')
#XXX: Conflict: contributor is category and dublin core property
#software_release.setContributor(person.getRelativeUrl())
software_release.setContributorValue(person)
self.assertFalse(consistency_message_existence in getMessageList(
software_release))
person_2 = self.portal.person_module.newContent(
portal_type='Person')
#XXX: Conflict: contributor is category and dublin core property
#software_release.setContributorList([person.getRelativeUrl(),
# person_2.getRelativeUrl()])
software_release.setContributorValueList([person, person_2])
self.assertTrue(consistency_message_existence in getMessageList(
software_release))
#XXX: Conflict: contributor is category and dublin core property
#software_release.setContributor(person.getRelativeUrl())
software_release.setContributorValue(person)
self.assertTrue(consistency_message_state in getMessageList(
software_release))
person.validate()
self.assertFalse(consistency_message_state in getMessageList(
software_release))
def test_reference(self):
consistency_message = 'Reference must be defined'
......
475
\ No newline at end of file
476
\ No newline at end of file
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment