@@ -25,7 +25,7 @@ async def test_offer(event_loop):
2525 await model .block_until (
2626 lambda : all (offer .application_name == 'ubuntu'
2727 for offer in offers .results ))
28- await model .remove_offer ("admin/{}.ubuntu" .format (model .info . name ), force = True )
28+ await model .remove_offer ("admin/{}.ubuntu" .format (model .name ), force = True )
2929
3030
3131@base .bootstrapped
@@ -49,13 +49,13 @@ async def test_consume(event_loop):
4949
5050 # farm off a new model to test the consumption
5151 async with base .CleanModel () as model_2 :
52- await model_2 .consume ("admin/{}.ubuntu" .format (model_1 .info . name ))
52+ await model_2 .consume ("admin/{}.ubuntu" .format (model_1 .name ))
5353
5454 status = await model_2 .get_status ()
5555 if 'ubuntu' not in status .remote_applications :
5656 raise Exception ("Expected ubuntu in saas" )
5757
58- await model_1 .remove_offer ("admin/{}.ubuntu" .format (model_1 .info . name ), force = True )
58+ await model_1 .remove_offer ("admin/{}.ubuntu" .format (model_1 .name ), force = True )
5959
6060
6161@base .bootstrapped
@@ -79,7 +79,7 @@ async def test_remove_saas(event_loop):
7979
8080 # farm off a new model to test the consumption
8181 async with base .CleanModel () as model_2 :
82- await model_2 .consume ("admin/{}.ubuntu" .format (model_1 .info . name ))
82+ await model_2 .consume ("admin/{}.ubuntu" .format (model_1 .name ))
8383
8484 await model_2 .remove_saas ('ubuntu' )
8585 await jasyncio .sleep (5 )
@@ -88,7 +88,7 @@ async def test_remove_saas(event_loop):
8888 if 'ubuntu' in status .remote_applications :
8989 raise Exception ("Expected ubuntu not to be in saas" )
9090
91- await model_1 .remove_offer ("admin/{}.ubuntu" .format (model_1 .info . name ), force = True )
91+ await model_1 .remove_offer ("admin/{}.ubuntu" .format (model_1 .name ), force = True )
9292
9393
9494@base .bootstrapped
@@ -123,7 +123,7 @@ async def test_relate_with_offer(event_loop):
123123 lambda : all (unit .agent_status == 'idle'
124124 for unit in application .units ))
125125
126- await model_2 .relate ("mediawiki:db" , "admin/{}.mysql" .format (model_1 .info . name ))
126+ await model_2 .relate ("mediawiki:db" , "admin/{}.mysql" .format (model_1 .name ))
127127 status = await model_2 .get_status ()
128128 if 'mysql' not in status .remote_applications :
129129 raise Exception ("Expected mysql in saas" )
@@ -135,7 +135,7 @@ async def test_relate_with_offer(event_loop):
135135 if 'mysql' in status .remote_applications :
136136 raise Exception ("Expected mysql not to be in saas" )
137137
138- await model_1 .remove_offer ("admin/{}.mysql" .format (model_1 .info . name ), force = True )
138+ await model_1 .remove_offer ("admin/{}.mysql" .format (model_1 .name ), force = True )
139139
140140
141141@base .bootstrapped
@@ -160,7 +160,7 @@ async def test_add_bundle(event_loop):
160160 try :
161161 tmp_path = str (Path (dirpath ) / 'bundle.yaml' )
162162 with open (tmp_path , "w" ) as file :
163- file .write (file_contents .format (model_1 .info . name ))
163+ file .write (file_contents .format (model_1 .name ))
164164 except IOError :
165165 raise
166166
@@ -186,4 +186,4 @@ async def test_add_bundle(event_loop):
186186 await model_2 .deploy ('local:{}' .format (tmp_path ))
187187 await model_2 .wait_for_idle (status = "active" )
188188
189- await model_1 .remove_offer ("admin/{}.influxdb" .format (model_1 .info . name ), force = True )
189+ await model_1 .remove_offer ("admin/{}.influxdb" .format (model_1 .name ), force = True )
0 commit comments