Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- diff --git a/test/basic_auth_plug_test.exs b/test/basic_auth_plug_test.exs
- new file mode 100644
- index 0000000..6153cb5
- --- /dev/null
- +++ b/test/basic_auth_plug_test.exs
- @@ -0,0 +1,15 @@
- +defmodule BasicAuthExercise.BasicAuthPlugTest do
- + use ExUnit.Case
- +
- + test "not passing :username raises an error" do
- + assert_raise KeyError, fn ->
- + BasicAuth.init(password: "secret")
- + end
- + end
- +
- + test "not passing :password raises an error" do
- + assert_raise KeyError, fn ->
- + BasicAuth.init(username: "user")
- + end
- + end
- +end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement