def test_get_url_with_https(self): registry = Registry() registry.set_credentials('username', 'password') url = registry.get_url('_catalog') self.assertEqual(url, 'https://localhost:5000/v2/_catalog')
def test_create_registry_with_credentials(self): registry = Registry() registry.set_credentials('username', 'password') self.assertEqual(registry.username, 'username') self.assertEqual(registry.password, 'password') self.assertIn('auth', registry.http_params)