incubator-cloudstack-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From h...@apache.org
Subject git commit: Quickly add the license header before Chip finds out.
Date Sun, 02 Dec 2012 19:19:54 GMT
Updated Branches:
  refs/heads/master 751e74708 -> 0902f60c6


Quickly add the license header before Chip finds out.

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

Branch: refs/heads/master
Commit: 0902f60c61b311a933d01205cd481e9e367d6630
Parents: 751e747
Author: Hugo Trippaers <trippie@gmail.com>
Authored: Sun Dec 2 11:19:32 2012 -0800
Committer: Hugo Trippaers <trippie@gmail.com>
Committed: Sun Dec 2 11:19:32 2012 -0800

----------------------------------------------------------------------
 .../network/resource/NiciraNvpResourceTest.java    |   25 +++++++++++++++
 1 files changed, 25 insertions(+), 0 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/blob/0902f60c/plugins/network-elements/nicira-nvp/test/com/cloud/network/resource/NiciraNvpResourceTest.java
----------------------------------------------------------------------
diff --git a/plugins/network-elements/nicira-nvp/test/com/cloud/network/resource/NiciraNvpResourceTest.java
b/plugins/network-elements/nicira-nvp/test/com/cloud/network/resource/NiciraNvpResourceTest.java
index 9fd2cef..7632703 100644
--- a/plugins/network-elements/nicira-nvp/test/com/cloud/network/resource/NiciraNvpResourceTest.java
+++ b/plugins/network-elements/nicira-nvp/test/com/cloud/network/resource/NiciraNvpResourceTest.java
@@ -1,5 +1,22 @@
+// Licensed to the Apache Software Foundation (ASF) under one
+// or more contributor license agreements.  See the NOTICE file
+// distributed with this work for additional information
+// regarding copyright ownership.  The ASF licenses this file
+// to you under the Apache License, Version 2.0 (the
+// "License"); you may not use this file except in compliance
+// with the License.  You may obtain a copy of the License at
+//
+//   http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing,
+// software distributed under the License is distributed on an
+// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+// KIND, either express or implied.  See the License for the
+// specific language governing permissions and limitations
+// under the License.
 package com.cloud.network.resource;
 
+import static org.junit.Assert.*;
 import static org.mockito.Mockito.*;
 
 import java.util.Collections;
@@ -11,6 +28,7 @@ import javax.naming.ConfigurationException;
 import org.junit.Before;
 import org.junit.Test;
 
+import com.cloud.host.Host;
 import com.cloud.network.nicira.NiciraNvpApi;
 
 public class NiciraNvpResourceTest {
@@ -44,6 +62,13 @@ public class NiciraNvpResourceTest {
 		
 		verify(_nvpApi).setAdminCredentials("adminuser", "adminpass");
 		verify(_nvpApi).setControllerAddress("127.0.0.1");
+		
+		assertTrue("nvptestdevice".equals(_resource.getName()));
+		
+		/* Pretty lame test, but here to assure this plugin fails 
+		 * if the type name ever changes from L2Networking
+		 */ 
+		assertTrue(_resource.getType() == Host.Type.L2Networking);
 	}
 	
 }


Mime
View raw message