Fixed unit test to convert json from unicode
Project: http://git-wip-us.apache.org/repos/asf/stratos/repo
Commit: http://git-wip-us.apache.org/repos/asf/stratos/commit/ff25f2b2
Tree: http://git-wip-us.apache.org/repos/asf/stratos/tree/ff25f2b2
Diff: http://git-wip-us.apache.org/repos/asf/stratos/diff/ff25f2b2
Branch: refs/heads/master
Commit: ff25f2b28f991d5159c391e602bebd25bb781f62
Parents: a5efe91
Author: Chamila de Alwis <ch...@wso2.com>
Authored: Thu Feb 5 17:55:52 2015 +0530
Committer: Imesh Gunaratne <im...@apache.org>
Committed: Sat Feb 7 15:07:08 2015 +0530
----------------------------------------------------------------------
.../cartridgeagent/modules/artifactmgt/git/agentgithandler.py | 3 ++-
.../cartridgeagent/tests/test_git.py | 3 ++-
2 files changed, 4 insertions(+), 2 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/stratos/blob/ff25f2b2/components/org.apache.stratos.python.cartridge.agent/cartridgeagent/cartridgeagent/modules/artifactmgt/git/agentgithandler.py
----------------------------------------------------------------------
diff --git a/components/org.apache.stratos.python.cartridge.agent/cartridgeagent/cartridgeagent/modules/artifactmgt/git/agentgithandler.py b/components/org.apache.stratos.python.cartridge.agent/cartridgeagent/cartridgeagent/modules/artifactmgt/git/agentgithandler.py
index bf46860..2d9fc2e 100644
--- a/components/org.apache.stratos.python.cartridge.agent/cartridgeagent/cartridgeagent/modules/artifactmgt/git/agentgithandler.py
+++ b/components/org.apache.stratos.python.cartridge.agent/cartridgeagent/cartridgeagent/modules/artifactmgt/git/agentgithandler.py
@@ -84,7 +84,8 @@ class AgentGitHandler:
else:
# subscribing run.. need to clone
git_repo = AgentGitHandler.create_git_repo(repo_info)
- AgentGitHandler.log.debug("Cloning artifacts from %s for the first time", git_repo.repo_url)
+ AgentGitHandler.log.debug("Cloning artifacts from %s for the first time to %r",
+ git_repo.repo_url, git_repo.local_repo_path)
subscribe_run = True
AgentGitHandler.log.debug("Executing git clone: [tenant-id] %s [repo-url] %s",
git_repo.tenant_id, git_repo.repo_url)
http://git-wip-us.apache.org/repos/asf/stratos/blob/ff25f2b2/components/org.apache.stratos.python.cartridge.agent/cartridgeagent/tests/test_git.py
----------------------------------------------------------------------
diff --git a/components/org.apache.stratos.python.cartridge.agent/cartridgeagent/tests/test_git.py b/components/org.apache.stratos.python.cartridge.agent/cartridgeagent/tests/test_git.py
index ecfa677..aa70efd 100644
--- a/components/org.apache.stratos.python.cartridge.agent/cartridgeagent/tests/test_git.py
+++ b/components/org.apache.stratos.python.cartridge.agent/cartridgeagent/tests/test_git.py
@@ -65,4 +65,5 @@ def repo_object_decoder(obj):
:param obj: json object
:return:
"""
- return Repository(obj["repoURL"], obj["repoUsername"], obj["repoPassword"], obj["repoPath"], obj["tenantId"], obj["multitenant"], obj["commitEnabled"])
+ return Repository(str(obj["repoURL"]), str(obj["repoUsername"]), str(obj["repoPassword"]), str(obj["repoPath"]),
+ str(obj["tenantId"]), str(obj["multitenant"]), str(obj["commitEnabled"]))