Skip to content

Commit 01f03d2

Browse files
committed
tests, examples: remove field specifications using the default values
Another long and boring but monotopical commit. This one is probably holding the record for "most lines removed" in odxtools so far :) Signed-off-by: Andreas Lauser <[email protected]> Signed-off-by: Christian Hackenbeck <[email protected]>
1 parent 4a2e26a commit 01f03d2

10 files changed

+146
-4391
lines changed

examples/mksomersaultmodifiedpdx.py

-51
Original file line numberDiff line numberDiff line change
@@ -101,90 +101,41 @@ def find_named_object(item_list: list[T], name: str) -> T:
101101
# add a new "flic-flac" service
102102
flic_flac_request = Request(
103103
odx_id=OdxLinkId("somersault.RQ.flic_flac", doc_frags),
104-
oid=None,
105104
short_name="RQ_flic_flac",
106-
long_name=None,
107-
description=None,
108-
admin_data=None,
109-
sdgs=[],
110105
parameters=NamedItemList([
111106
CodedConstParameter(
112-
oid=None,
113107
short_name="sid",
114-
long_name=None,
115-
semantic=None,
116-
description=None,
117108
diag_coded_type=somersaultecu.somersault_diagcodedtypes["uint8"],
118109
byte_position=0,
119110
coded_value_raw=str(FLIC_FLAC_SID),
120-
bit_position=None,
121-
sdgs=[],
122111
)
123112
]),
124113
)
125114
somersault_young_dlr.requests.append(flic_flac_request)
126115

127116
flic_flac_positive_response = Response(
128117
odx_id=OdxLinkId("somersault.PR.flic_flac", doc_frags),
129-
oid=None,
130118
short_name="PR_flic_flac",
131-
long_name=None,
132-
description=None,
133-
admin_data=None,
134-
sdgs=[],
135119
response_type=ResponseType.POSITIVE,
136120
parameters=NamedItemList([
137121
CodedConstParameter(
138-
oid=None,
139122
short_name="sid",
140-
long_name=None,
141-
semantic=None,
142-
description=None,
143123
diag_coded_type=somersaultecu.somersault_diagcodedtypes["uint8"],
144124
byte_position=0,
145125
coded_value_raw=str(uds.positive_response_id(FLIC_FLAC_SID)),
146-
bit_position=None,
147-
sdgs=[],
148126
),
149127
ValueParameter(
150-
oid=None,
151128
short_name="can_do_backward_flips",
152-
long_name=None,
153-
semantic=None,
154-
description=None,
155-
physical_default_value_raw=None,
156129
byte_position=1,
157130
dop_ref=OdxLinkRef("somersault.DOP.boolean", doc_frags),
158-
dop_snref=None,
159-
bit_position=None,
160-
sdgs=[],
161131
),
162132
]),
163133
)
164134
somersault_young_dlr.positive_responses.append(flic_flac_positive_response)
165135

166136
flic_flac_service = DiagService(
167137
odx_id=OdxLinkId("somersault.service.flic_flac", doc_frags),
168-
oid=None,
169138
short_name="flic_flac",
170-
long_name=None,
171-
description=None,
172-
admin_data=None,
173-
protocol_snrefs=[],
174-
related_diag_comm_refs=[],
175-
diagnostic_class=None,
176-
is_mandatory_raw=None,
177-
is_executable_raw=None,
178-
is_final_raw=None,
179-
comparam_refs=[],
180-
is_cyclic_raw=None,
181-
is_multiple_raw=None,
182-
addressing_raw=None,
183-
transmission_mode_raw=None,
184-
audience=None,
185-
functional_class_refs=[],
186-
pre_condition_state_refs=[],
187-
state_transition_refs=[],
188139
semantic="FUNCTION",
189140
request_ref=OdxLinkRef.from_id(flic_flac_request.odx_id),
190141
pos_response_refs=[
@@ -193,8 +144,6 @@ def find_named_object(item_list: list[T], name: str) -> T:
193144
neg_response_refs=[
194145
OdxLinkRef.from_id(somersaultecu.somersault_negative_responses["general"].odx_id),
195146
],
196-
pos_response_suppressible=None,
197-
sdgs=[],
198147
)
199148

200149
# create a new list of diagnostic communications that does not include

0 commit comments

Comments
 (0)