Closed SivWatt closed 3 years ago
Merging #207 (6c2c208) into development (5111844) will increase coverage by
0.87%
. The diff coverage is81.81%
.
@@ Coverage Diff @@
## development #207 +/- ##
===============================================
+ Coverage 45.30% 46.18% +0.87%
===============================================
Files 27 28 +1
Lines 1342 1375 +33
===============================================
+ Hits 608 635 +27
- Misses 646 649 +3
- Partials 88 91 +3
Impacted Files | Coverage Δ | |
---|---|---|
internal/mail/mailgun.go | 80.64% <80.64%> (ø) |
|
internal/mail/mail.go | 58.33% <100.00%> (+8.33%) |
: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 5111844...6c2c208. Read the comment docs.
LGTM @PichuChen
👏 解決掉的 issue / Resolved Issues
📝 相關的 issue / Related Issues
191
⛏ 變更內容 / Details of Changes
mail.go
- 新增 case 呼叫新增 mailgun providermail_test.go
- 新增兩個測試關於NewMailProvider()
mailgun.go
- mailgun provider 實作mailgun_test.go
- 測試 mailgun provider其他
關於 mailgun provider test,我是用自己起一個 https server 的作法去測,這樣 Send 成功以及失敗就都可以被測到。 測試成功的部份有在 handler function 裡面對 request 做一些檢查,如果覺得這個部分不需要,其實也可以拿掉。 另外我新增了
mail_test.go
的想法是覺得NewMailProvider()
裡面的邏輯 應該是要在這個 test file 裡面驗證。