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

Rework devlocal methods to make signing in from /create easier #1824

Merged
merged 7 commits into from Mar 19, 2019

Conversation

2 participants
@chrisgilmerproj
Copy link
Contributor

chrisgilmerproj commented Mar 6, 2019

Description

To support load testing I need the /create method to be a little easier to work with. This PR reworks the way the methods interact with each other to streamline that a bit. I've also added some tests.

Setup

You can use this demo script to log in and see things working.

Code Review Verification Steps

  • Request review from a member of a different team.

References

@chrisgilmerproj chrisgilmerproj self-assigned this Mar 6, 2019

@chrisgilmerproj chrisgilmerproj requested review from jim and rdhariwal Mar 6, 2019

@codecov

This comment has been minimized.

Copy link

codecov bot commented Mar 6, 2019

Codecov Report

Merging #1824 into master will increase coverage by 0.15%.
The diff coverage is 46.25%.

@@            Coverage Diff             @@
##           master    #1824      +/-   ##
==========================================
+ Coverage   50.29%   50.44%   +0.15%     
==========================================
  Files         441      441              
  Lines       19098    19121      +23     
  Branches     1641     1641              
==========================================
+ Hits         9605     9646      +41     
+ Misses       8652     8619      -33     
- Partials      841      856      +15
@rdhariwal

This comment has been minimized.

Copy link
Contributor

rdhariwal commented Mar 18, 2019

Looks good to me over all, might need a rebase/merge and I ll bless it :)

chrisgilmerproj added some commits Mar 18, 2019

h.logger.Info("Disabled user requesting authentication", zap.Error(err), zap.String("email", session.Email))
http.Error(w, http.StatusText(403), http.StatusForbidden)
return nil
}

This comment has been minimized.

@chrisgilmerproj

chrisgilmerproj Mar 18, 2019

Author Contributor

This is because of the merge. Instead of throwing a 403 directly when fetching the userIdentity I have to throw the Disabled value into the session and then check it afterwards. It's not my favorite method but it keeps the concerns separated.

@chrisgilmerproj

This comment has been minimized.

Copy link
Contributor Author

chrisgilmerproj commented Mar 18, 2019

@rdhariwal - Take another look after the tests pass please :)

@rdhariwal
Copy link
Contributor

rdhariwal left a comment

:shipit:

chrisgilmerproj added some commits Mar 19, 2019

@chrisgilmerproj chrisgilmerproj merged commit ae6c8a2 into master Mar 19, 2019

18 of 19 checks passed

codecov/patch 46.25% of diff hit (target 50.29%)
Details
Codacy/PR Quality Review Up to standards. A positive pull request.
Details
ci/circleci: acceptance_tests_experimental Your tests passed on CircleCI!
Details
ci/circleci: acceptance_tests_local Your tests passed on CircleCI!
Details
ci/circleci: acceptance_tests_staging Your tests passed on CircleCI!
Details
ci/circleci: build_app Your tests passed on CircleCI!
Details
ci/circleci: build_migrations Your tests passed on CircleCI!
Details
ci/circleci: build_tools Your tests passed on CircleCI!
Details
ci/circleci: client_test Your tests passed on CircleCI!
Details
ci/circleci: client_test_coverage Your tests passed on CircleCI!
Details
ci/circleci: integration_tests_mymove Your tests passed on CircleCI!
Details
ci/circleci: integration_tests_office Your tests passed on CircleCI!
Details
ci/circleci: integration_tests_tsp Your tests passed on CircleCI!
Details
ci/circleci: pre_deps_golang Your tests passed on CircleCI!
Details
ci/circleci: pre_deps_yarn Your tests passed on CircleCI!
Details
ci/circleci: pre_test Your tests passed on CircleCI!
Details
ci/circleci: server_test Your tests passed on CircleCI!
Details
ci/circleci: server_test_coverage Your tests passed on CircleCI!
Details
codecov/project 50.44% (+0.15%) compared to 827d18a
Details

@chrisgilmerproj chrisgilmerproj deleted the cg_streamline_devlocal_login branch Mar 19, 2019

@chrisgilmerproj chrisgilmerproj referenced this pull request Mar 22, 2019

Open

WIP - Try out load testing framework locust.io #1597

0 of 2 tasks complete
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.