Did I find the right examples for you? yes no

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

src/t/u/tuskar-0.4.1/tuskar/tests/test_utils.py   tuskar(Download)
            "/this/is/a/fake", cache_data, reload_func=test_reload)
        self.assertEqual(data, fake_contents)
        self.assertTrue(self.reload_called)
 
 
class IntLikeTestCase(base.TestCase):
 
    def test_is_int_like(self):
        self.assertTrue(utils.is_int_like(1))
        self.assertTrue(utils.is_int_like("1"))
    def test_is_int_like(self):
        self.assertTrue(utils.is_int_like(1))
        self.assertTrue(utils.is_int_like("1"))
        self.assertTrue(utils.is_int_like("514"))
        self.assertTrue(utils.is_int_like("0"))

src/t/u/tuskar-HEAD/tuskar/tests/test_utils.py   tuskar(Download)
                                                reload_func=test_reload)
        self.assertEqual(data, fake_contents)
        self.assertTrue(self.reload_called)
 
 
class IntLikeTestCase(base.TestCase):
 
    def test_is_int_like(self):
        self.assertTrue(utils.is_int_like(1))
        self.assertTrue(utils.is_int_like("1"))
    def test_is_int_like(self):
        self.assertTrue(utils.is_int_like(1))
        self.assertTrue(utils.is_int_like("1"))
        self.assertTrue(utils.is_int_like("514"))
        self.assertTrue(utils.is_int_like("0"))

src/t/u/tuskar-0.4.1/tuskar/tests/api/controllers/v1/test_overcloud.py   tuskar(Download)
        # Verify
        self.assertEqual(response.status_int, 200)
        self.assertTrue(isinstance(result, list))
        self.assertEqual(1, len(result))
        self.assertEqual(result[0]['name'], 'foo')
        self.assertEqual(1, mock_db_create.call_count)
        db_create_model = mock_db_create.call_args[0][0]
        self.assertTrue(isinstance(db_create_model,
                                   db_models.Overcloud))
        self.assertEqual(db_create_model.name, create_me['name'])
        self.assertEqual(1, mock_db_update.call_count)
        db_update_model = mock_db_update.call_args[0][0]
        self.assertTrue(isinstance(db_update_model,
                                   db_models.Overcloud))
        self.assertEqual(db_update_model.id, 12345)

src/t/u/tuskar-0.4.1/tuskar/tests/api/controllers/v1/test_overcloud_roles.py   tuskar(Download)
        # Verify
        self.assertEqual(response.status_int, 200)
        self.assertTrue(isinstance(result, list))
        self.assertEqual(1, len(result))
        self.assertEqual(result[0]['name'], 'foo')
        self.assertEqual(1, mock_db_create.call_count)
        db_create_model = mock_db_create.call_args[0][0]
        self.assertTrue(isinstance(db_create_model,
                                   db_models.OvercloudRole))
        self.assertEqual(db_create_model.name, create_me['name'])
        self.assertEqual(1, mock_db_update.call_count)
        db_update_model = mock_db_update.call_args[0][0]
        self.assertTrue(isinstance(db_update_model,
                                   db_models.OvercloudRole))
        self.assertEqual(db_update_model.id, 12345)