adriangb / xpresso

A composable Python ASGI web framework
https://xpresso-api.dev/
MIT License
178 stars 4 forks source link

refactor/feat: add `scheme_name` to Security() and refactor security / binders #40

Closed adriangb closed 2 years ago

adriangb commented 2 years ago

Closes #24

Big diff, mostly from moving files around which cascaded into many import changes. Some meaty code updates as well. Most of it is internal though, aside from the addition of the scheme_name keyword to Security().

codecov-commenter commented 2 years ago

Codecov Report

Merging #40 (622dab1) into main (4d5b8a9) will decrease coverage by 0.70%. The diff coverage is 95.83%.

@@            Coverage Diff             @@
##             main      #40      +/-   ##
==========================================
- Coverage   98.16%   97.45%   -0.71%     
==========================================
  Files         179      178       -1     
  Lines        5611     5697      +86     
  Branches      656      673      +17     
==========================================
+ Hits         5508     5552      +44     
- Misses         56       98      +42     
  Partials       47       47              
Impacted Files Coverage Δ
...aram_constraints_and_metadata/test_tutorial_001.py 100.00% <ø> (ø)
...st_docs/tutorial/query_params/test_tutorial_001.py 100.00% <ø> (ø)
...st_docs/tutorial/query_params/test_tutorial_003.py 100.00% <ø> (ø)
xpresso/_utils/schemas.py 100.00% <ø> (ø)
xpresso/applications.py 96.25% <ø> (-0.49%) :arrow_down:
.../binders/_body/extractors/body_field_validation.py 81.81% <ø> (ø)
xpresso/binders/_body/extractors/discriminated.py 73.17% <ø> (ø)
xpresso/binders/_body/extractors/field.py 94.28% <ø> (ø)
xpresso/binders/_body/extractors/form_field.py 92.59% <ø> (ø)
xpresso/binders/_body/openapi/discriminated.py 81.39% <ø> (ø)
... and 41 more