-
-
Notifications
You must be signed in to change notification settings - Fork 1
Issue #5 delete existing experience feature #40
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
base: main
Are you sure you want to change the base?
Conversation
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.
Pull Request Overview
This PR adds a DELETE endpoint for experiences and corresponding tests to support the deletion feature for resume experiences.
- Adds a new DELETE endpoint in app.py to remove an experience by its index
- Implements a pytest function in test_pytest.py to test the creation and deletion flow for an experience
Reviewed Changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated no comments.
| File | Description |
|---|---|
| test_pytest.py | Added a test for the DELETE /resume/experience/int:exp_id endpoint |
| app.py | Introduced a new DELETE endpoint to remove an experience by index |
Comments suppressed due to low confidence (2)
app.py:224
- Using the list index as the experience ID can be fragile if the ordering of experiences changes. Consider using a unique identifier for each experience and updating the deletion logic accordingly.
if 0 <= exp_id < len(data["experience"]):
test_pytest.py:324
- Since the GET endpoint returns a list of dicts that may include extra fields not present in 'example_experience', consider improving the check. For example, verify that no experience in the list has a matching unique identifier or defined fields from the created experience.
assert example_experience not in experiences
|
can you please fix the merge conflicts and i'll approve? |
A Delete endpoint for /resume/experience/int:exp_id has been added to app.py to allow deleting an experience by its index.