コード例 #1
0
ファイル: test_hosts.py プロジェクト: nati/nova
    def test_list_hosts(self):
        """Verify that the compute hosts are returned."""
        hosts = os_hosts._list_hosts(self.req)
        self.assertEqual(hosts, HOST_LIST)

        compute_hosts = os_hosts._list_hosts(self.req, "compute")
        expected = [host for host in HOST_LIST if host["service"] == "compute"]
        self.assertEqual(compute_hosts, expected)
コード例 #2
0
ファイル: test_hosts.py プロジェクト: xtoddx/nova
    def test_list_hosts(self):
        """Verify that the compute hosts are returned."""
        hosts = os_hosts._list_hosts(self.req)
        self.assertEqual(hosts, HOST_LIST)

        compute_hosts = os_hosts._list_hosts(self.req, "compute")
        expected = [host for host in HOST_LIST if host["service"] == "compute"]
        self.assertEqual(compute_hosts, expected)
コード例 #3
0
ファイル: test_hosts.py プロジェクト: whitekid/nova
 def test_list_hosts_with_zone(self):
     req = FakeRequestWithNovaZone()
     hosts = os_hosts._list_hosts(req)
     self.assertEqual(hosts, HOST_LIST_NOVA_ZONE)
コード例 #4
0
ファイル: test_hosts.py プロジェクト: chiehwen/nova
 def test_list_hosts(self):
     # Verify that the compute hosts are returned.
     hosts = os_hosts._list_hosts(self.req)
     self.assertEqual(hosts, HOST_LIST['hosts'])
コード例 #5
0
 def test_list_hosts(self):
     """Verify that the compute hosts are returned."""
     hosts = os_hosts._list_hosts(self.req)
     self.assertEqual(hosts, HOST_LIST['hosts'])
コード例 #6
0
ファイル: test_hosts.py プロジェクト: duankai/nova
 def test_list_hosts(self):
     """Verify that the compute hosts are returned."""
     hosts = os_hosts._list_hosts(self.req)
     self.assertEqual(hosts, HOST_LIST["hosts"])