@@ -38,6 +38,7 @@ def _make_one(self, *args, **kw):
3838 return self ._get_target_class ()(* args , ** kw )
3939
4040 def test_ctor (self ):
41+ from google .api_core .client_info import ClientInfo
4142 from google .cloud .dns ._http import Connection
4243
4344 creds = _make_credentials ()
@@ -46,6 +47,23 @@ def test_ctor(self):
4647 self .assertIsInstance (client ._connection , Connection )
4748 self .assertIs (client ._connection .credentials , creds )
4849 self .assertIs (client ._connection .http , http )
50+ self .assertIsInstance (client ._connection ._client_info , ClientInfo )
51+
52+ def test_ctor_w_client_info (self ):
53+ from google .api_core .client_info import ClientInfo
54+ from google .cloud .dns ._http import Connection
55+
56+ client_info = ClientInfo ()
57+
58+ creds = _make_credentials ()
59+ http = object ()
60+ client = self ._make_one (
61+ project = self .PROJECT , credentials = creds , _http = http , client_info = client_info
62+ )
63+ self .assertIsInstance (client ._connection , Connection )
64+ self .assertIs (client ._connection .credentials , creds )
65+ self .assertIs (client ._connection .http , http )
66+ self .assertIs (client ._connection ._client_info , client_info )
4967
5068 def test_quotas_defaults (self ):
5169 PATH = "projects/%s" % (self .PROJECT ,)
0 commit comments