-
Notifications
You must be signed in to change notification settings - Fork 5
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add tests targeting core functionality of /data_objects/study/{study_id}
endpoint
#849
Add tests targeting core functionality of /data_objects/study/{study_id}
endpoint
#849
Conversation
Hi @sujaypatil96, I created this branch on which I've written some tests that target some of the core functionality of the |
Mermaid diagram describing instance relationships in the example/scenario used in graph LR
nmdc:bsm-11-6zd5nb38 -- "associated_studies" --> nmdc:sty-11-r2h77870
nmdc:bsm-11-6zd5nb38 -- "has_input" --> nmdc:omprc-11-nmtj1g51
nmdc:omprc-11-nmtj1g51 -- "was_informed_by" --> nmdc:wfmsa-11-fqq66x60.1
nmdc:wfmsa-11-fqq66x60.1 -- "has_output" --> nmdc:dobj-11-cpv4y420
|
@sujaypatil96 I think our "setup" is incomplete. It seems like there needs to be a |
@dwinston yes you're right! This is what the
|
…tudy_id-endpoint-is-not-being-tested
this is ready for review and merge. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There's a test case for the /data_objects/study/{study_id}
endpoint in the test suite now. There's a mermaid diagram that captures the scenario we are simulating.
We're basically looking for an expected DataObject
id in the response JSON for the /data_objects/study/{study_id}
for a given study id and that works.
Note
This branch is under construction.
In this branch, I implemented some pytest tests that exercise the core functionality of the
/data_objects/study/{study_id}
endpoint.Details
The tests do not currently exercise all of the core functionality of that endpoint. I plan to hand this branch off to someone else to fill in the gaps (by following the "example" tests I have added here).
Related issue(s)
Eventually, this PR will fix #725.
Related subsystem(s)
docs
directory)Testing
I tested these changes by running
$ make test-run
on this branch, where thetest-run
Make target has been redefined locally as:Documentation
docs
directory)Maintainability
study_id: str
)# TODO
or# FIXME
black
to format all the Python files I created/modified