dwyl / dwyl/library

Ensure lib/library_web/controllers/plugs/require_auth.ex is covered by tests

Open
#43 0 comments 0 reactions 0 assignees View on GitHub
awaiting-review priority-3 T25m technical
Dominant language
Elixir
Stars
16
Forks
1
PR merge metrics
No merged PRs in 30d

Description

I have created the lib/library_web/controllers/plugs/require_auth.ex plug so that we can protect routes by login, however in #38 it is not used anywhere, the easiest (and most effective, IMO) way to test a plug to check auth is to use the normal way to test a controller, but with both a user set on the connection, and no user on the connection, so you can ensure you know the results of both. Due to this I have added `lib/library_web/controllers/plugs/require_auth.ex` to the files igfnored by coveralls, but once we use it somewhere, we must ensure it is covered, and remove it from the list of ignored files.

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.