• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

mbland / elistman / 5481053858 / 1
100%
main: 100%

Build:
DEFAULT BRANCH: main
Ran 06 Jul 2023 11:22PM UTC
Files 38
Run time 0s
Badge
Embed ▾
README BADGES
x

If you need to use a raster PNG badge, change the '.svg' to '.png' in the link

Markdown

Textile

RDoc

HTML

Rst

06 Jul 2023 11:12PM UTC coverage: 100.0%. Remained the same
5481053858.1

push

github

mbland
TestHandleApiRequest: use POST unsubscribe

This is in preparation for allowing only POST unsubscribe requests.

The handler logic doesn't care what HTTP method is used to unsubscribe,
which is why this test change didn't require any code changes. The
/unsubscribe HTTP method is enforced by the CloudFormation template.

Still, it's good for the test input to closely resemble what's expected
from the configured API Gateway, even if it doesn't affect the handler
logic.

I mean, I could add logic to enforce the expected HTTP method for each
API endpoint. Maybe that's not a bad idea. However, it will have to come
after updating the system to point {{UnsubscribeUrl}} at a page with a
web form.

That, in fact, is why I'm diving into making sure `@` is encoded as
`%40` and thinking of eliminating GET /unsubscribe. I accidentally
unsubscribed myself by clicking on the unsubscribe link in an email.
Updating {{UnsubscribeUrl}} to point to a form will allow the user to
make sure they really intend to unsubscribe. This POST /unsubscribe will
be less error prone while also being more semantically correct. (I think
technically /verify should also be a POST, but it seems conventional to
have such links always use GET.)

2240 of 2240 relevant lines covered (100.0%)

15.97 hits per line

Source Files on job 5481053858.1
  • Tree
  • List 38
  • Changed 1
  • Source Changed 1
  • Coverage Changed 1
Coverage ∆ File Lines Relevant Covered Missed Hits/Line
  • Back to Build 5481053858
  • 890afc99 on github
  • Prev Job for on main (#5468114781.1)
  • Next Job for on main (#5496041830.1)
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc