File tree Expand file tree Collapse file tree 1 file changed +10
-6
lines changed
tests/integration_tests/functional Expand file tree Collapse file tree 1 file changed +10
-6
lines changed Original file line number Diff line number Diff line change @@ -95,13 +95,17 @@ def test_rescan_dev(test_microvm_with_ssh, network_config):
95
95
losetup_result = run (losetup , stdout = PIPE , check = True )
96
96
loopback_device = losetup_result .stdout .decode ('utf-8' ).rstrip ()
97
97
98
- response = test_microvm .drive .patch (
99
- drive_id = 'scratch' ,
100
- path_on_host = test_microvm .create_jailed_resource (loopback_device ),
101
- )
102
- assert test_microvm .api_session .is_status_no_content (response .status_code )
98
+ try :
99
+ response = test_microvm .drive .patch (
100
+ drive_id = 'scratch' ,
101
+ path_on_host = test_microvm .create_jailed_resource (loopback_device ),
102
+ )
103
+ assert test_microvm .api_session .is_status_no_content (response .status_code )
104
+
105
+ _check_scratch_size (ssh_connection , fs2 .size ())
106
+ finally :
107
+ run (['losetup' , '-d' , loopback_device ], check = True )
103
108
104
- _check_scratch_size (ssh_connection , fs2 .size ())
105
109
106
110
107
111
def test_non_partuuid_boot (test_microvm_with_ssh , network_config ):
You can’t perform that action at this time.
0 commit comments