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 tests for userservice and supporting refactor #128

Merged
merged 6 commits into from
Apr 22, 2020

Conversation

bharathkkb
Copy link
Member

Changelist
part of #51

  • Add tests for userservice
  • Refactor db ops to a seperate module to increase testability
  • Refactor Flask app to follow application factory pattern
    -- enables users to run userservice locally using flask dev server python3 userservice.py
    -- easier to create test instances

Copy link
Member

@daniel-sanche daniel-sanche left a comment

Choose a reason for hiding this comment

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

I added a few small comments, but overall this looks great!

src/userservice/userservice.py Outdated Show resolved Hide resolved
src/userservice/userservice.py Outdated Show resolved Hide resolved
src/userservice/userservice.py Outdated Show resolved Hide resolved
.github/workflows/smoke-tests.yml Show resolved Hide resolved
src/userservice/tests/test_userservice.py Show resolved Hide resolved
src/userservice/tests/test_userservice.py Outdated Show resolved Hide resolved
src/userservice/tests/test_userservice.py Outdated Show resolved Hide resolved
src/userservice/tests/test_userservice.py Outdated Show resolved Hide resolved
Copy link
Member

@daniel-sanche daniel-sanche left a comment

Choose a reason for hiding this comment

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

One more small request: Can you mention the python unit tests in the workflow README?

Other than that, LGTM

add unit test to workfloe

clean deps, add venv to sh script

address comments

descriptive unit test function names
@bharathkkb bharathkkb added this to the Release v0.2.0 milestone Apr 18, 2020
src/userservice/.dockerigone Show resolved Hide resolved
.github/workflows/smoke-tests.yml Show resolved Hide resolved
.github/workflows/smoke-tests.yml Show resolved Hide resolved
src/userservice/tests/test_userservice.py Show resolved Hide resolved
Copy link
Contributor

@murog murog left a comment

Choose a reason for hiding this comment

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

🎉

@bharathkkb bharathkkb merged commit 0c9db27 into master Apr 22, 2020
@murog murog mentioned this pull request May 12, 2020
2 tasks
@askmeegs askmeegs deleted the add-user-svc-tests branch August 20, 2020 17:59
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.

None yet

4 participants