Fix SoftwareProcessEntityTest.MyService - Set the SERVICE_STATE_ACTUAL, rather than leaving the attribute always saying Lifecycle.CREATED
Project: http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/repo Commit: http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/commit/7fd92be5 Tree: http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/tree/7fd92be5 Diff: http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/diff/7fd92be5 Branch: refs/heads/master Commit: 7fd92be51e3cd1e791d4a7060610399d77ac1713 Parents: 4e625b9 Author: Aled Sage <[email protected]> Authored: Fri Jun 26 14:47:02 2015 +0100 Committer: Aled Sage <[email protected]> Committed: Thu Jul 2 17:20:19 2015 +0100 ---------------------------------------------------------------------- .../java/brooklyn/entity/basic/SoftwareProcessEntityTest.java | 3 +++ 1 file changed, 3 insertions(+) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/blob/7fd92be5/software/base/src/test/java/brooklyn/entity/basic/SoftwareProcessEntityTest.java ---------------------------------------------------------------------- diff --git a/software/base/src/test/java/brooklyn/entity/basic/SoftwareProcessEntityTest.java b/software/base/src/test/java/brooklyn/entity/basic/SoftwareProcessEntityTest.java index 55deb4e..70bc416 100644 --- a/software/base/src/test/java/brooklyn/entity/basic/SoftwareProcessEntityTest.java +++ b/software/base/src/test/java/brooklyn/entity/basic/SoftwareProcessEntityTest.java @@ -507,6 +507,7 @@ public class SoftwareProcessEntityTest extends BrooklynAppUnitTestSupport { events.add("stop"); launched = false; entity.setAttribute(Startable.SERVICE_UP, false); + entity.setAttribute(SoftwareProcess.SERVICE_STATE_ACTUAL, Lifecycle.STOPPED); } @Override @@ -519,6 +520,7 @@ public class SoftwareProcessEntityTest extends BrooklynAppUnitTestSupport { @Override public void install() { events.add("install"); + entity.setAttribute(SoftwareProcess.SERVICE_STATE_ACTUAL, Lifecycle.STARTING); } @Override @@ -531,6 +533,7 @@ public class SoftwareProcessEntityTest extends BrooklynAppUnitTestSupport { events.add("launch"); launched = true; entity.setAttribute(Startable.SERVICE_UP, true); + entity.setAttribute(SoftwareProcess.SERVICE_STATE_ACTUAL, Lifecycle.RUNNING); } @Override
