From f26413d8d7a50d3674afb18bd49833a46ab3d646 Mon Sep 17 00:00:00 2001 From: Adrian Cole Date: Fri, 30 Sep 2011 10:49:58 -0700 Subject: [PATCH] formatting --- .../predicates/NodePredicatesTest.java | 48 +++++++++---------- 1 file changed, 24 insertions(+), 24 deletions(-) diff --git a/compute/src/test/java/org/jclouds/compute/predicates/NodePredicatesTest.java b/compute/src/test/java/org/jclouds/compute/predicates/NodePredicatesTest.java index 365259791c..0abfcd9cb9 100644 --- a/compute/src/test/java/org/jclouds/compute/predicates/NodePredicatesTest.java +++ b/compute/src/test/java/org/jclouds/compute/predicates/NodePredicatesTest.java @@ -44,39 +44,39 @@ public class NodePredicatesTest { public void setUp() throws Exception { node = createMock(NodeMetadata.class); computeService = createMock(ComputeService.class); - + expect(node.getId()).andReturn("myid").anyTimes(); expect(computeService.getNodeMetadata("myid")).andReturn(node).anyTimes(); expect(node.getLocation()).andReturn(null).anyTimes(); } - + @Test public void testNodeRunningReturnsTrueWhenRunning() { - expect(node.getState()).andReturn(NodeState.RUNNING).atLeastOnce(); - replay(node); - replay(computeService); - - NodeRunning nodeRunning = new NodeRunning(computeService); - Assert.assertTrue(nodeRunning.apply(node)); + expect(node.getState()).andReturn(NodeState.RUNNING).atLeastOnce(); + replay(node); + replay(computeService); + + NodeRunning nodeRunning = new NodeRunning(computeService); + Assert.assertTrue(nodeRunning.apply(node)); } - @Test(expectedExceptions=IllegalStateException.class) + @Test(expectedExceptions = IllegalStateException.class) public void testNodeRunningFailsOnTerminated() { - expect(node.getState()).andReturn(NodeState.TERMINATED).atLeastOnce(); - replay(node); - replay(computeService); - - NodeRunning nodeRunning = new NodeRunning(computeService); - nodeRunning.apply(node); - } - - @Test(expectedExceptions=IllegalStateException.class) - public void testNodeRunningFailsOnError() { - expect(node.getState()).andReturn(NodeState.ERROR).atLeastOnce(); - replay(node); - replay(computeService); + expect(node.getState()).andReturn(NodeState.TERMINATED).atLeastOnce(); + replay(node); + replay(computeService); - NodeRunning nodeRunning = new NodeRunning(computeService); - nodeRunning.apply(node); + NodeRunning nodeRunning = new NodeRunning(computeService); + nodeRunning.apply(node); + } + + @Test(expectedExceptions = IllegalStateException.class) + public void testNodeRunningFailsOnError() { + expect(node.getState()).andReturn(NodeState.ERROR).atLeastOnce(); + replay(node); + replay(computeService); + + NodeRunning nodeRunning = new NodeRunning(computeService); + nodeRunning.apply(node); } }