Skip to content

Commit a8bff14

Browse files
authored
[uss_qualifier] use set_uss_available fragment in cleanup (#1273)
1 parent ba0707c commit a8bff14

File tree

3 files changed

+3
-24
lines changed

3 files changed

+3
-24
lines changed

monitoring/uss_qualifier/scenarios/astm/utm/off_nominal_planning/down_uss.md

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -102,8 +102,7 @@ If the planning was accepted, Flight 1 should have been shared.
102102
If the planning was rejected, Flight 1 should not have been shared, thus should not exist.
103103

104104
## Cleanup
105-
### 🛑 Availability of virtual USS restored check
106-
**[astm.f3548.v21.DSS0100,1](../../../../requirements/astm/f3548/v21.md)**
105+
### [Restore virtual USS availability test step](../set_uss_available.md)
107106

108107
### 🛑 Successful flight deletion check
109108
Delete flights injected at USS through the flight planning interface.

monitoring/uss_qualifier/scenarios/astm/utm/off_nominal_planning/down_uss.py

Lines changed: 1 addition & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
from uas_standards.astm.f3548.v21.api import (
22
OperationalIntentReference,
33
OperationalIntentState,
4-
UssAvailabilityState,
54
)
65
from uas_standards.astm.f3548.v21.constants import Scope
76

@@ -303,25 +302,7 @@ def _clear_op_intents(self):
303302

304303
def cleanup(self):
305304
self.begin_cleanup()
306-
307-
with self.check(
308-
"Availability of virtual USS restored", [self.dss.participant_id]
309-
) as check:
310-
try:
311-
availability_version, avail_query = self.dss.set_uss_availability(
312-
self.uss_qualifier_sub,
313-
UssAvailabilityState.Normal,
314-
)
315-
self.record_query(avail_query)
316-
except QueryError as e:
317-
self.record_queries(e.queries)
318-
avail_query = e.queries[0]
319-
check.record_failed(
320-
summary=f"Availability of USS {self.uss_qualifier_sub} could not be set to available",
321-
details=f"DSS responded code {avail_query.status_code}; {e}",
322-
query_timestamps=[avail_query.request.timestamp],
323-
)
324-
305+
set_uss_available(self, self.dss, self.uss_qualifier_sub)
325306
cleanup_flights(self, [self.tested_uss])
326307
self._clear_op_intents()
327308

monitoring/uss_qualifier/scenarios/astm/utm/off_nominal_planning/down_uss_equal_priority_not_permitted.md

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -173,8 +173,7 @@ to reject or accept Flight 2. If the USS indicates that the injection attempt fa
173173

174174

175175
## Cleanup
176-
### 🛑 Availability of virtual USS restored check
177-
**[astm.f3548.v21.DSS0100,1](../../../../requirements/astm/f3548/v21.md)**
176+
### [Restore virtual USS availability test step](../set_uss_available.md)
178177

179178
### 🛑 Successful flight deletion check
180179
Delete flights injected at USS through the flight planning interface.

0 commit comments

Comments
 (0)