social-core icon indicating copy to clipboard operation
social-core copied to clipboard

vk: improve code quality

Open blacktrub opened this issue 3 years ago • 1 comments

Proposed changes

I wanted to improve code quality of a VK back-end, because I had a problem when I wanted to extend it. So I decided it's a good idea to move vk_api function to class implementation, so we can use an inheritance with full power.

Types of changes

Please check the type of change your PR introduces:

  • [ ] Release (new release request)
  • [ ] Bugfix (non-breaking change which fixes an issue)
  • [ ] New feature (non-breaking change which adds functionality)
  • [ ] Code style update (PEP8, lint, formatting, renaming, etc)
  • [x] Refactoring (no functional changes, no api changes)
  • [ ] Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • [ ] Build related changes (build process, tests runner, etc)
  • [ ] Other (please describe):

Checklist

Put an x in the boxes that apply. You can also fill these out after creating the PR. If you're unsure about any of them, don't hesitate to ask. We're here to help! This is simply a reminder of what we are going to look for before merging your code.

  • [x] Lint and unit tests pass locally with my changes
  • [ ] I have added tests that prove my fix is effective or that my feature works

Other information

Any other information that is important to this PR such as screenshots of how the component looks before and after the change.

blacktrub avatar Sep 21 '21 18:09 blacktrub

Codecov Report

Merging #617 (eb9dfd2) into master (1ea27e8) will decrease coverage by 0.00%. The diff coverage is 48.38%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master     #617      +/-   ##
==========================================
- Coverage   76.92%   76.92%   -0.01%     
==========================================
  Files         317      317              
  Lines        9630     9641      +11     
  Branches      962      964       +2     
==========================================
+ Hits         7408     7416       +8     
- Misses       2071     2073       +2     
- Partials      151      152       +1     
Flag Coverage Δ
unittests 76.92% <48.38%> (-0.01%) :arrow_down:

Flags with carried forward coverage won't be shown. Click here to find out more.

Impacted Files Coverage Δ
social_core/backends/vk.py 43.63% <48.38%> (+3.23%) :arrow_up:

Continue to review full report at Codecov.

Legend - Click here to learn more Δ = absolute <relative> (impact), ø = not affected, ? = missing data Powered by Codecov. Last update 1ea27e8...eb9dfd2. Read the comment docs.

codecov[bot] avatar Sep 21 '21 19:09 codecov[bot]