Update the test for OMF
[nepi.git] / src / nepi / resources / omf / application.py
index a7f131b..55ca910 100644 (file)
@@ -41,7 +41,7 @@ class OMFApplication(OMFResource):
 
     """
     _rtype = "OMFApplication"
-    _authorized_connections = ["OMFNode"]
+    _authorized_connections = ["OMFNode", "WilabtSfaNode"]
 
     @classmethod
     def _register_attributes(cls):
@@ -55,11 +55,11 @@ class OMFApplication(OMFResource):
         appid = Attribute("appid", "Name of the application")
         stdin = Attribute("stdin", "Input of the application", default = "")
         sources = Attribute("sources", "Sources of the application", 
-                     flags = Flags.ExecReadOnly)
+                     flags = Flags.Design)
         sshuser = Attribute("sshUser", "user to connect with ssh", 
-                     flags = Flags.ExecReadOnly)
+                     flags = Flags.Design)
         sshkey = Attribute("sshKey", "key to use for ssh", 
-                     flags = Flags.ExecReadOnly)
+                     flags = Flags.Design)
 
         cls._register_attribute(appid)
         cls._register_attribute(command)
@@ -335,7 +335,7 @@ class OMFApplication(OMFResource):
 
         """
         if self._omf_api:
-            if self.get('version') == "6":
+            if self.get('version') == "6" and self._topic_app:
                 if not self.release_id:
                     self.release_id = os.urandom(16).encode('hex')
                     self._omf_api.frcp_release( self.release_id, self.node.get('hostname'),self._topic_app, res_id=self._topic_app)