Commit 649854de authored by Titouan Soulard's avatar Titouan Soulard Committed by Romain Courteaud

slapos_jio_api_style: add alarm script to tests

parent d51555ed
...@@ -25,7 +25,7 @@ ...@@ -25,7 +25,7 @@
# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. # Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
# #
############################################################################## ##############################################################################
from erp5.component.test.SlapOSTestCaseMixin import SlapOSTestCaseMixin from erp5.component.test.SlapOSTestCaseMixin import SlapOSTestCaseMixin, TemporaryAlarmScript
from DateTime import DateTime from DateTime import DateTime
...@@ -1508,13 +1508,14 @@ class TestSlapOSSlapToolPersonAccess(TestSlapOSJIOAPIMixin): ...@@ -1508,13 +1508,14 @@ class TestSlapOSSlapToolPersonAccess(TestSlapOSJIOAPIMixin):
self.callUpdateRevision() self.callUpdateRevision()
self.tic() self.tic()
self.login(self.person_user_id) self.login(self.person_user_id)
instance_dict = self.postToApi({ with TemporaryAlarmScript(self.portal, 'Item_getSubscriptionStatus', "'subscribed'"):
"portal_type": "Software Instance", instance_dict = self.postToApi({
"software_release_uri": instance.getUrlString(), "portal_type": "Software Instance",
"software_type": instance.getSourceReference(), "software_release_uri": instance.getUrlString(),
"title": instance.getTitle(), "software_type": instance.getSourceReference(),
"project_reference": self.project.getReference() "title": instance.getTitle(),
}) "project_reference": self.project.getReference()
})
response = self.portal.REQUEST.RESPONSE response = self.portal.REQUEST.RESPONSE
if 201 != response.getStatus(): if 201 != response.getStatus():
......
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