You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@ariatosca.apache.org by mx...@apache.org on 2017/05/16 18:31:12 UTC

incubator-ariatosca git commit: fixed ssh tests

Repository: incubator-ariatosca
Updated Branches:
  refs/heads/runtime_props_to_attr 8e60d3f44 -> b47ad4295


fixed ssh tests


Project: http://git-wip-us.apache.org/repos/asf/incubator-ariatosca/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-ariatosca/commit/b47ad429
Tree: http://git-wip-us.apache.org/repos/asf/incubator-ariatosca/tree/b47ad429
Diff: http://git-wip-us.apache.org/repos/asf/incubator-ariatosca/diff/b47ad429

Branch: refs/heads/runtime_props_to_attr
Commit: b47ad4295549f938a80d81b6c3a9e3542a3e5da1
Parents: 8e60d3f
Author: max-orlov <ma...@gigaspaces.com>
Authored: Tue May 16 21:31:08 2017 +0300
Committer: max-orlov <ma...@gigaspaces.com>
Committed: Tue May 16 21:31:08 2017 +0300

----------------------------------------------------------------------
 tests/orchestrator/execution_plugin/test_ssh.py |  8 +++---
 tests/resources/scripts/test_ssh.sh             | 30 ++++++++++----------
 2 files changed, 19 insertions(+), 19 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-ariatosca/blob/b47ad429/tests/orchestrator/execution_plugin/test_ssh.py
----------------------------------------------------------------------
diff --git a/tests/orchestrator/execution_plugin/test_ssh.py b/tests/orchestrator/execution_plugin/test_ssh.py
index a9dc5e8..e83a779 100644
--- a/tests/orchestrator/execution_plugin/test_ssh.py
+++ b/tests/orchestrator/execution_plugin/test_ssh.py
@@ -53,9 +53,9 @@ _FABRIC_ENV = {
 class TestWithActualSSHServer(object):
 
     def test_run_script_basic(self):
-        expected_runtime_property_value = 'some_value'
-        props = self._execute(env={'test_value': expected_runtime_property_value})
-        assert props['test_value'] == expected_runtime_property_value
+        expected_attribute_value = 'some_value'
+        props = self._execute(env={'test_value': expected_attribute_value})
+        assert props['test_value'] == expected_attribute_value
 
     @pytest.mark.skip(reason='sudo privileges are required')
     def test_run_script_as_sudo(self):
@@ -260,7 +260,7 @@ class TestWithActualSSHServer(object):
             tasks_graph=tasks_graph)
         eng.execute()
         return self._workflow_context.model.node.get_by_name(
-            mock.models.DEPENDENCY_NODE_NAME).runtime_properties
+            mock.models.DEPENDENCY_NODE_NAME).attributes
 
     def _execute_and_get_task_exception(self, *args, **kwargs):
         signal = events.on_failure_task_signal

http://git-wip-us.apache.org/repos/asf/incubator-ariatosca/blob/b47ad429/tests/resources/scripts/test_ssh.sh
----------------------------------------------------------------------
diff --git a/tests/resources/scripts/test_ssh.sh b/tests/resources/scripts/test_ssh.sh
index 90202c7..bbdf773 100644
--- a/tests/resources/scripts/test_ssh.sh
+++ b/tests/resources/scripts/test_ssh.sh
@@ -4,7 +4,7 @@ set -u
 set -e
 
 test_run_script_basic() {
-    ctx node runtime-properties test_value $test_value
+    ctx node attributes test_value $test_value
 }
 
 test_run_script_as_sudo() {
@@ -12,7 +12,7 @@ test_run_script_as_sudo() {
 }
 
 test_run_script_default_base_dir() {
-    ctx node runtime-properties work_dir $PWD
+    ctx node attributes work_dir $PWD
 }
 
 test_run_script_with_hide() {
@@ -20,44 +20,44 @@ test_run_script_with_hide() {
 }
 
 test_run_script_process_config() {
-    ctx node runtime-properties env_value $test_value_env
-    ctx node runtime-properties bash_version $BASH_VERSION
-    ctx node runtime-properties arg1_value $1
-    ctx node runtime-properties arg2_value $2
-    ctx node runtime-properties cwd $PWD
-    ctx node runtime-properties ctx_path $(which ctx)
+    ctx node attributes env_value $test_value_env
+    ctx node attributes bash_version $BASH_VERSION
+    ctx node attributes arg1_value $1
+    ctx node attributes arg2_value $2
+    ctx node attributes cwd $PWD
+    ctx node attributes ctx_path $(which ctx)
 }
 
 test_run_script_command_prefix() {
-    ctx node runtime-properties dollar_dash $-
+    ctx node attributes dollar_dash $-
 }
 
 test_run_script_reuse_existing_ctx_1() {
-    ctx node runtime-properties test_value1 $test_value1
+    ctx node attributes test_value1 $test_value1
 }
 
 test_run_script_reuse_existing_ctx_2() {
-    ctx node runtime-properties test_value2 $test_value2
+    ctx node attributes test_value2 $test_value2
 }
 
 test_run_script_download_resource_plain() {
     local destination=$(mktemp)
     ctx download-resource ${destination} test_resource
-    ctx node runtime-properties test_value "$(cat ${destination})"
+    ctx node attributes test_value "$(cat ${destination})"
 }
 
 test_run_script_download_resource_and_render() {
     local destination=$(mktemp)
     ctx download-resource-and-render ${destination} test_resource
-    ctx node runtime-properties test_value "$(cat ${destination})"
+    ctx node attributes test_value "$(cat ${destination})"
 }
 
 test_run_script_inputs_as_env_variables_no_override() {
-    ctx node runtime-properties test_value "$custom_env_var"
+    ctx node attributes test_value "$custom_env_var"
 }
 
 test_run_script_inputs_as_env_variables_process_env_override() {
-    ctx node runtime-properties test_value "$custom_env_var"
+    ctx node attributes test_value "$custom_env_var"
 }
 
 test_run_script_error_in_script() {