2 Tests for generated client code
8 from juju
.client
import client
13 for i
in range(1, 5): # Assert versions 1-4 in client dict
14 assert str(i
) in client
.CLIENTS
17 def test_from_connection():
18 connection
= mock
.Mock()
19 connection
.facades
= {"Action": 2}
20 action_facade
= client
.ActionFacade
.from_connection(connection
)
25 uml
= client
.UserModelList([client
.UserModel()])
26 assert uml
.to_json() == ('{"user-models": [{"last-connection": null, '