diff options
author | Skip Wonnell <kw5258@att.com> | 2017-08-29 14:16:20 -0500 |
---|---|---|
committer | Skip Wonnell <kw5258@att.com> | 2017-08-30 08:17:34 -0500 |
commit | 8c9631e438b9491424df0f43d43445f098436834 (patch) | |
tree | c355ed09a765614a9be25d1e6e88b06b753d7f30 /appc-adapters/appc-chef-adapter/appc-chef-adapter-bundle/src/test | |
parent | 51f905f307dde5e1c5135515796c614250e9de4d (diff) |
ChefAdapter code clean-up
Issue-ID: APPC-90
Change-Id: I582d6b0c81d5a89938fff6038dfcc221ccaf19c1
Signed-off-by: Skip Wonnell <kw5258@att.com>
Diffstat (limited to 'appc-adapters/appc-chef-adapter/appc-chef-adapter-bundle/src/test')
-rw-r--r-- | appc-adapters/appc-chef-adapter/appc-chef-adapter-bundle/src/test/java/org/openecomp/appc/adapter/chef/impl/TestChefAdapterImpl.java | 13 |
1 files changed, 6 insertions, 7 deletions
diff --git a/appc-adapters/appc-chef-adapter/appc-chef-adapter-bundle/src/test/java/org/openecomp/appc/adapter/chef/impl/TestChefAdapterImpl.java b/appc-adapters/appc-chef-adapter/appc-chef-adapter-bundle/src/test/java/org/openecomp/appc/adapter/chef/impl/TestChefAdapterImpl.java index d9b172aba..744f84722 100644 --- a/appc-adapters/appc-chef-adapter/appc-chef-adapter-bundle/src/test/java/org/openecomp/appc/adapter/chef/impl/TestChefAdapterImpl.java +++ b/appc-adapters/appc-chef-adapter/appc-chef-adapter-bundle/src/test/java/org/openecomp/appc/adapter/chef/impl/TestChefAdapterImpl.java @@ -72,18 +72,17 @@ public class TestChefAdapterImpl { @Before public void setup() throws IllegalArgumentException, IllegalAccessException { - adapter = new ChefAdapterImpl(); + adapter = new ChefAdapterImpl(System.getProperty("user.dir")+"/src/main/resources/client.pem"); } - + @Test public void testChefGet() throws IOException, IllegalStateException, IllegalArgumentException, ZoneException, APPCException { Map<String, String> params = new HashMap<>(); params.put("org.openecomp.appc.instance.chefAction", "/nodes"); - - - SvcLogicContext svcContext = new SvcLogicContext(); + + SvcLogicContext svcContext = new SvcLogicContext(); adapter.chefGet(params, svcContext); String status=svcContext.getAttribute("org.openecomp.appc.chefServerResult.code"); assertEquals("200",status); @@ -98,7 +97,7 @@ public class TestChefAdapterImpl { params.put("org.openecomp.appc.instance.chefAction", "/nodes/testnode"); params.put("org.openecomp.appc.instance.runList", "recipe[commandtest]"); params.put("org.openecomp.appc.instance.attributes", ""); - SvcLogicContext svcContext = new SvcLogicContext(); + SvcLogicContext svcContext = new SvcLogicContext(); adapter.chefPut(params, svcContext); String status=svcContext.getAttribute("org.openecomp.appc.chefServerResult.code"); assertEquals("200",status); @@ -111,7 +110,7 @@ public class TestChefAdapterImpl { Map<String, String> params = new HashMap<>(); params.put("org.openecomp.appc.instance.ip", "http://example.com/test"); - SvcLogicContext svcContext = new SvcLogicContext(); + SvcLogicContext svcContext = new SvcLogicContext(); adapter.trigger(params, svcContext); String status=svcContext.getAttribute("org.openecomp.appc.chefAgent.code"); assertEquals("200",status); |