Did I find the right examples for you? yes no      Crawl my project      Python Jobs

All Samples(10)  |  Call(10)  |  Derive(0)  |  Import(0)

src/s/a/sahara-HEAD/sahara/tests/unit/plugins/vanilla/test_utils.py   sahara(Download)
        cl = tu.create_cluster('cl1', 't1', 'vanilla', '1.2.1',
                               [self.ng_manager])
        self.assertIsNone(u.get_namenode(cl))
 
    def test_get_jobtracker(self):
        cl = tu.create_cluster('cl1', 't1', 'vanilla', '1.2.1',
                               [self.ng_manager])
        self.assertIsNone(u.get_jobtracker(cl))
 
    def test_get_oozie(self):
        cl = tu.create_cluster('cl1', 't1', 'vanilla', '1.2.1',
                               [self.ng_manager])
        self.assertIsNone(u.get_oozie(cl))
 
    def test_get_hiveserver(self):
        cl = tu.create_cluster('cl1', 't1', 'vanilla', '1.2.1',
                               [self.ng_manager])
        self.assertIsNone(u.get_hiveserver(cl))
 
    def test_get_datanodes(self):

src/s/a/sahara-HEAD/sahara/tests/unit/service/test_volumes.py   sahara(Download)
        execute_com = instance.remote().execute_command
 
        self.assertIsNone(volumes._mount_volume(instance, '123', '456'))
        self.assertEqual(execute_com.call_count, 3)
 
        p_delete.return_value = None
        self.assertIsNone(
            volumes.detach_from_instance(instance))
 
        p_delete.side_effect = RuntimeError
        instance = r.InstanceResource({'instance_id': '123454321',
                                       'instance_name': 'instt'})
        self.assertIsNone(volumes._await_attach_volumes(instance, 2))
        self.assertRaises(RuntimeError, volumes._await_attach_volumes,
                          instance, 3)

src/s/a/sahara-2014.1/sahara/tests/unit/service/test_volumes.py   sahara(Download)
        execute_com = instance.remote().execute_command
 
        self.assertIsNone(volumes._mount_volume(instance, '123', '456'))
        self.assertEqual(execute_com.call_count, 3)
 
        p_delete.return_value = None
        self.assertIsNone(
            volumes.detach_from_instance(instance))
 
        p_delete.side_effect = RuntimeError
        instance = r.InstanceResource({'instance_id': '123454321',
                                       'instance_name': 'instt'})
        self.assertIsNone(volumes._await_attach_volumes(instance, 2))
        self.assertRaises(RuntimeError, volumes._await_attach_volumes,
                          instance, 3)