Skip to content
This repository has been archived by the owner on Mar 27, 2024. It is now read-only.

Sourcery Starbot ⭐ refactored DillonB07/GitAPI #20

Merged
merged 1 commit into from
Feb 13, 2022

Conversation

SourceryAI
Copy link
Contributor

Thanks for starring sourcery-ai/sourcery ✨ 🌟 ✨

Here's your pull request refactoring your most popular Python repo.

If you want Sourcery to refactor all your Python repos and incoming pull requests install our bot.

Review changes via command line

To manually merge these changes, make sure you're on the master branch, then run:

git fetch https://github.com/sourcery-ai-bot/GitAPI master
git merge --ff-only FETCH_HEAD
git reset HEAD^

Comment on lines -14 to +15
if response['data']['user']['login'] == 'DillonB07':
output = True
else:
output = False
assert output == True
output = response['data']['user']['login'] == 'DillonB07'
assert output
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Function test_user_info refactored with the following changes:

Comment on lines -23 to +21
if response['data']['repository']['nameWithOwner'] == 'DillonB07/GitAPI':
output = True
else:
output = False
assert output == True
output = response['data']['repository']['nameWithOwner'] == 'DillonB07/GitAPI'
assert output
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Function test_repo_info refactored with the following changes:

Comment on lines -45 to +39
assert output == True
assert output
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Function test_custom_query refactored with the following changes:

@sourcery-ai
Copy link

sourcery-ai bot commented Feb 13, 2022

Sourcery Code Quality Report

✅  Merging this PR will increase code quality in the affected files by 1.12%.

Quality metrics Before After Change
Complexity 1.20 ⭐ 0.67 ⭐ -0.53 👍
Method Length 36.57 ⭐ 34.28 ⭐ -2.29 👍
Working memory 7.30 🙂 7.11 🙂 -0.19 👍
Quality 82.52% 83.64% 1.12% 👍
Other metrics Before After Change
Lines 78 72 -6
Changed files Quality Before Quality After Quality Change
src/tests/test_graphql.py 82.52% ⭐ 83.64% ⭐ 1.12% 👍

Here are some functions in these files that still need a tune-up:

File Function Complexity Length Working Memory Quality Recommendation

Legend and Explanation

The emojis denote the absolute quality of the code:

  • ⭐ excellent
  • 🙂 good
  • 😞 poor
  • ⛔ very poor

The 👍 and 👎 indicate whether the quality has improved or gotten worse with this pull request.


Please see our documentation here for details on how these metrics are calculated.

We are actively working on this report - lots more documentation and extra metrics to come!

Help us improve this quality report!

@transcental transcental merged commit 8704216 into transcental:master Feb 13, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants