Skip to content
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 child questions backend code #146

Open
wants to merge 11 commits into
base: main
Choose a base branch
from
Open

Conversation

MaHaWo
Copy link
Collaborator

@MaHaWo MaHaWo commented Nov 6, 2024

  • add ChildQuestion and ChildAnswer database models
  • add default child questions which are added when the database is initialized
    • name
    • birth date
    • remarks
    • optional file upload for image
      These are intended to fill the Child model upon registration of a new child. They have fixed question-ids of 1 to 4 in the ChildQuestion table in the above order.
  • add tests for new code
  • unify model classes via inheritance for questions, answers where easily possible, i.e., where no sql tables are involved.
  • sonarcloud complaint is about about duplication in autogenerated code. Not sure if this should be adressed.

a substantial chunk of the changed LoC is autogenerated openapi code, so this PR isn´t quite as big as it seems.

@MaHaWo MaHaWo changed the title add child questions backend code from pr 138 add child questions backend code Nov 6, 2024
@codecov-commenter
Copy link

codecov-commenter commented Nov 6, 2024

Codecov Report

Attention: Patch coverage is 94.53125% with 7 lines in your changes missing coverage. Please review.

Project coverage is 29.21%. Comparing base (06f1284) to head (e0a16f4).

Files with missing lines Patch % Lines
...backend/src/mondey_backend/databases/milestones.py 25.00% 6 Missing ⚠️
mondey_backend/src/mondey_backend/routers/users.py 96.66% 1 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main     #146      +/-   ##
==========================================
+ Coverage   26.83%   29.21%   +2.38%     
==========================================
  Files          93       93              
  Lines        3455     3550      +95     
  Branches      122      122              
==========================================
+ Hits          927     1037     +110     
+ Misses       2461     2446      -15     
  Partials       67       67              

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@MaHaWo MaHaWo requested a review from lkeegan November 6, 2024 15:18
Copy link

sonarcloud bot commented Nov 6, 2024

Quality Gate Failed Quality Gate failed

Failed conditions
6.6% Duplication on New Code (required ≤ 3%)

See analysis details on SonarCloud

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants