File tree Expand file tree Collapse file tree 3 files changed +23
-0
lines changed
Expand file tree Collapse file tree 3 files changed +23
-0
lines changed Original file line number Diff line number Diff line change @@ -241,6 +241,14 @@ class Change(BaseModel):
241241
242242 A change to the model or model state, corresponding to an individual
243243 row of the PEtab conditions table.
244+
245+ >>> Change(
246+ ... target_id="k1",
247+ ... operation_type=OperationType.SET_CURRENT_VALUE,
248+ ... target_value="10",
249+ ... ) # doctest: +NORMALIZE_WHITESPACE
250+ Change(target_id='k1', operation_type='setCurrentValue',
251+ target_value=10.0000000000000)
244252 """
245253
246254 #: The ID of the target entity to change
@@ -286,6 +294,19 @@ class ChangeSet(BaseModel):
286294 A set of simultaneously occurring changes to the model or model state,
287295 corresponding to a perturbation of the underlying system. This corresponds
288296 to all rows of the PEtab conditions table with the same condition ID.
297+
298+ >>> ChangeSet(
299+ ... id="condition1",
300+ ... changes=[
301+ ... Change(
302+ ... target_id="k1",
303+ ... operation_type=OperationType.SET_CURRENT_VALUE,
304+ ... target_value="10",
305+ ... )
306+ ... ],
307+ ... ) # doctest: +NORMALIZE_WHITESPACE
308+ ChangeSet(id='condition1', changes=[Change(target_id='k1',
309+ operation_type='setCurrentValue', target_value=10.0000000000000)])
289310 """
290311
291312 #: The condition ID
Original file line number Diff line number Diff line change @@ -114,6 +114,7 @@ convention = "pep257"
114114"tests/*" = [" T201" ]
115115
116116[tool .ruff .format ]
117+ docstring-code-format = true
117118exclude = [
118119 " petab/math/_generated/*" , # auto-generated
119120]
Original file line number Diff line number Diff line change 11[pytest]
2+ addopts = --doctest-modules
23filterwarnings =
34 error
45 # TODO: until tests are reorganized for petab.v1
You can’t perform that action at this time.
0 commit comments