-
Notifications
You must be signed in to change notification settings - Fork 0
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
Send Email #17
Send Email #17
Conversation
Codecov Report
@@ Coverage Diff @@
## master #17 +/- ##
============================================
+ Coverage 87.50% 100.00% +12.50%
============================================
Files 18 16 -2
Lines 72 70 -2
============================================
+ Hits 63 70 +7
+ Misses 9 0 -9
Continue to review full report at Codecov.
|
@SimonLab as you can see from the Codecov Coverage report, coverage is still below 100% 🙄 To get this working on Heroku you will need to have the two environment variables defined (as per the instructions in the Let me know if anything is unclear or you have any questions. |
@@ -3,6 +3,9 @@ | |||
"minimum_coverage": 100 | |||
}, | |||
"skip_files": [ | |||
"test/" | |||
"test/", | |||
"lib/auth_mvp_web.ex", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
we aren't directly using these files so they aren't covered by tests hence adding them here.
@@ -28,3 +28,6 @@ config :phoenix, :json_library, Jason | |||
# Import environment specific config. This must remain at the bottom | |||
# of this file so it overrides the configuration defined above. | |||
import_config "#{Mix.env()}.exs" | |||
|
|||
# https://hexdocs.pm/joken/introduction.html#usage | |||
config :joken, default_signer: System.get_env("SECRET_KEY_BASE") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this needs to match the SECRET_KEY_BASE
on dashboard.heroku.com/apps/dwylmail/settings for email to work.
@@ -4,5 +4,9 @@ defmodule AuthMvpWeb.GithubAuthControllerTest do | |||
test "GET /auth/github/callback", %{conn: conn} do | |||
conn = get(conn, Routes.github_auth_path(conn, :index, %{code: "123", state: "http://localhost/"})) | |||
assert html_response(conn, 302) | |||
|
|||
# same again to exercise to the branch where person already exists: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
you were already so close to 100% coverage that I just added these extra lines to get to 💯
(hope you don't mind ...)
@SimonLab please excuse the flood of commits tidying up ... 🙄 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks great, thanks @nelsonic
@SimonLab this PR sends a
welcome
email to people who authenticate with Google/GitHub.