You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@couchdb.apache.org by GitBox <gi...@apache.org> on 2022/06/17 09:40:01 UTC

[GitHub] [couchdb] jjrodrig commented on a diff in pull request #4041: Allow and evaluate nested json claim roles

jjrodrig commented on code in PR #4041:
URL: https://github.com/apache/couchdb/pull/4041#discussion_r899953971


##########
test/elixir/test/jwt_roles_claim_test.exs:
##########
@@ -0,0 +1,126 @@
+defmodule JwtRolesClaimTest do
+  use CouchTestCase
+
+  @testdb "jwttestdb"
+
+  @global_server_config [
+    %{
+      :section => "chttpd",
+      :key => "authentication_handlers",
+      :value => [
+                  "{chttpd_auth, jwt_authentication_handler}, ",
+                  "{chttpd_auth, cookie_authentication_handler}, ",
+                  "{chttpd_auth, default_authentication_handler})"
+                ] |> Enum.join
+    },
+    %{
+      :section => "jwt_keys",
+      :key => "hmac:myjwttestkey",
+      :value => ~w(
+        NTNv7j0TuYARvmNMmWXo6fKvM4o6nv/aUi9ryX38ZH+L1bkrnD1ObOQ8JAUmHCBq7
+        Iy7otZcyAagBLHVKvvYaIpmMuxmARQ97jUVG16Jkpkp1wXOPsrF9zwew6TpczyH
+        kHgX5EuLg2MeBuiT/qJACs1J0apruOOJCg/gOtkjB4c=) |> Enum.join()
+    }
+  ]
+
+  setup do

Review Comment:
   Hi @big-r81 
   Just a question, do you need to create a testdb? It seems that the _session endpoint is the only involved here.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@couchdb.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org