|
| 1 | +# ASTM SCD DSS: Operational Intent Reference Key Validation test scenario |
| 2 | + |
| 3 | +## Overview |
| 4 | + |
| 5 | +Verifies that a DSS requires from a client creating or updating operational intent references that they |
| 6 | +provide all OVNs for all currently relevant entities. |
| 7 | + |
| 8 | +## Resources |
| 9 | + |
| 10 | +### dss |
| 11 | + |
| 12 | +[`DSSInstanceResource`](../../../../resources/astm/f3548/v21/dss.py) the DSS instance through which entities are created, modified and deleted. |
| 13 | + |
| 14 | +### id_generator |
| 15 | + |
| 16 | +[`IDGeneratorResource`](../../../../resources/interuss/id_generator.py) providing the base entity ID for this scenario. |
| 17 | + |
| 18 | +### client_identity |
| 19 | + |
| 20 | +[`ClientIdentityResource`](../../../../resources/communications/client_identity.py) the client identity that will be used to create and update operational intent references. |
| 21 | + |
| 22 | +### planning_area |
| 23 | + |
| 24 | +[`PlanningAreaResource`](../../../../resources/astm/f3548/v21/planning_area.py) describes the 3D volume in which operational intent references will be created. |
| 25 | + |
| 26 | +## Setup test case |
| 27 | + |
| 28 | +### [Ensure clean workspace test step](./clean_workspace.md) |
| 29 | + |
| 30 | +This step ensures that no entities with the known test IDs exists in the DSS. |
| 31 | + |
| 32 | +## Key Validation test case |
| 33 | + |
| 34 | +This test case will create multiple operational intent references and verify that the `key` field |
| 35 | +of the parameters to create or update an operational intent reference is properly validated. |
| 36 | + |
| 37 | +That is: the DSS should require that the client provides the OVNs for each entity that is in the vicinity, |
| 38 | +both geographically and temporally, of the client's operational intent reference. |
| 39 | + |
| 40 | +### Create non-overlapping OIRs test step |
| 41 | + |
| 42 | +This first test step creates two operational intent references that do not overlap in time, and |
| 43 | +should therefore both not require any entry in the `key` field. |
| 44 | + |
| 45 | +#### 🛑 First operational intent reference in area creation query succeeds check |
| 46 | + |
| 47 | +With no potentially conflicting entity present, the DSS is expected to allow the creation of an operational intent without |
| 48 | +the client specifying any OVN in the `key` field. |
| 49 | + |
| 50 | +If the DSS rejects a well-formed request to create the operational intent reference, it is in violation of **[astm.f3548.v21.DSS0005,1](../../../../requirements/astm/f3548/v21.md)**. |
| 51 | + |
| 52 | +#### 🛑 Second, non-overlapping operational intent reference creation succeeds check |
| 53 | + |
| 54 | +With a single existing OIR in the area that is not overlapping in time, the DSS is expected to allow the creation of an operational intent without |
| 55 | +the client specifying any OVN in the `key` field. |
| 56 | + |
| 57 | +If the DSS rejects a well-formed request to create the operational intent reference, it is in violation of **[astm.f3548.v21.DSS0005,1](../../../../requirements/astm/f3548/v21.md)**. |
| 58 | + |
| 59 | +### Attempt creation of overlapping OIRs test step |
| 60 | + |
| 61 | +This test step will attempt to create various operational intent references that intersect with either one or both of the previously created ones, |
| 62 | +and expect the DSS to require the relevant OVNs to be provided in the `key` field. |
| 63 | + |
| 64 | +Note that this step will optionally validate the response body for `HTTP 409` error responses from the DSS when these contain the expected `missing_operational_intents` field. |
| 65 | + |
| 66 | +At the end of this step, the DSS is expected to have accepted the creation of 3 operational intent references, |
| 67 | +with one of them overlapping with the two others. |
| 68 | + |
| 69 | +#### 🛑 Create operational intent reference with missing OVN fails check |
| 70 | + |
| 71 | +If the DSS allows the creation of an operational intent reference that is missing the required OVNs for other entities that exist in its geo-temporal vicinity, |
| 72 | +it is in violation of **[astm.f3548.v21.DSS0005,1](../../../../requirements/astm/f3548/v21.md)** and **[astm.f3548.v21.DSS0210,A2-7-2,2a](../../../../requirements/astm/f3548/v21.md)** |
| 73 | + |
| 74 | +#### 🛑 Failure response due to conflict has proper format check |
| 75 | + |
| 76 | +The DSS is expected to return a `HTTP 409` error response when the creation of an operational intent reference fails due to a conflict. |
| 77 | +This response is expected to conform to the OpenAPI spec that is part of **[astm.f3548.v21.DSS0005,1](../../../../requirements/astm/f3548/v21.md)**. |
| 78 | + |
| 79 | +Should this not be the case, then the DSS is in violation of the aforementioned requirement. |
| 80 | + |
| 81 | +#### 🛑 Failure response due to conflict contains conflicting OIRs check |
| 82 | + |
| 83 | +If the DSS returns a `HTTP 409` error response due to a conflict, and the response body contains a `missing_operational_intents` field, |
| 84 | +this field is expected to contain the conflicting OVNs. |
| 85 | + |
| 86 | +If the field exists but does not contain the conflicting OVNs, then the DSS is in violation of **[astm.f3548.v21.DSS0005,1](../../../../requirements/astm/f3548/v21.md)**. |
| 87 | + |
| 88 | +#### 🛑 Create operational intent reference with proper OVNs succeeds check |
| 89 | + |
| 90 | +If the DSS prevents the creation of an operational intent reference that is providing all required OVNs for other entities that exist in its geo-temporal vicinity, |
| 91 | +it is in violation of **[astm.f3548.v21.DSS0005,1](../../../../requirements/astm/f3548/v21.md)**. |
| 92 | + |
| 93 | +### Attempt mutation of operational intent reference with overlaps test step |
| 94 | + |
| 95 | +This test step will attempt to mutate an existing operational intent reference so that it overlaps with other, already existing ones. |
| 96 | + |
| 97 | +The expectation is that the DSS will require the OVNs of any operational intent that would overlap with the result of the mutation to be provided in the `key` field. |
| 98 | + |
| 99 | +#### 🛑 Mutate operational intent reference with missing OVN fails check |
| 100 | + |
| 101 | +If the DSS allows the mutation of an operational intent reference that is missing the required OVNs for other entities that exist in its geo-temporal vicinity, |
| 102 | +it is in violation of **[astm.f3548.v21.DSS0005,1](../../../../requirements/astm/f3548/v21.md)** and **[astm.f3548.v21.DSS0210,A2-7-2,2b](../../../../requirements/astm/f3548/v21.md)** |
| 103 | + |
| 104 | +#### 🛑 Failure response due to conflict has proper format check |
| 105 | + |
| 106 | +The DSS is expected to return a `HTTP 409` error response when the creation of an operational intent reference fails due to a conflict. |
| 107 | +This response is expected to conform to the OpenAPI spec that is part of **[astm.f3548.v21.DSS0005,1](../../../../requirements/astm/f3548/v21.md)**. |
| 108 | + |
| 109 | +Should this not be the case, then the DSS is in violation of the aforementioned requirement. |
| 110 | + |
| 111 | +#### 🛑 Failure response due to conflict contains conflicting OIRs check |
| 112 | + |
| 113 | +If the DSS returns a `HTTP 409` error response due to a conflict, and the response body contains a `missing_operational_intents` field, |
| 114 | +this field is expected to contain the conflicting OVNs. |
| 115 | + |
| 116 | +If the field exists but does not contain the conflicting OVNs, then the DSS is in violation of **[astm.f3548.v21.DSS0005,1](../../../../requirements/astm/f3548/v21.md)**. |
| 117 | + |
| 118 | + |
| 119 | +## [Cleanup](./clean_workspace.md) |
0 commit comments