diff --git a/lib/tempest/xrpc/server.ex b/lib/tempest/xrpc/server.ex index 1b1bc51..80a55f7 100644 --- a/lib/tempest/xrpc/server.ex +++ b/lib/tempest/xrpc/server.ex @@ -13,10 +13,9 @@ defmodule Tempest.Xrpc.Server do did: "did:web:#{config.hostname}", availableUserDomains: [available_user_domain(config.hostname)], inviteCodeRequired: false, - links: %{ - privacyPolicy: nil, - termsOfService: nil - } + phoneVerificationRequired: false, + links: %{}, + contact: %{} }} end diff --git a/test/smoke/deployment.hurl b/test/smoke/deployment.hurl index 685f731..032cd18 100644 --- a/test/smoke/deployment.hurl +++ b/test/smoke/deployment.hurl @@ -26,8 +26,9 @@ header "content-type" contains "application/json" jsonpath "$.did" exists jsonpath "$.availableUserDomains" exists jsonpath "$.inviteCodeRequired" == false -jsonpath "$.links.privacyPolicy" exists -jsonpath "$.links.termsOfService" exists +jsonpath "$.phoneVerificationRequired" == false +jsonpath "$.links" exists +jsonpath "$.contact" exists GET {{base_url}}/.well-known/oauth-protected-resource HTTP 200 diff --git a/test/smoke/xrpc.hurl b/test/smoke/xrpc.hurl index 5f285a5..1539c82 100644 --- a/test/smoke/xrpc.hurl +++ b/test/smoke/xrpc.hurl @@ -11,8 +11,9 @@ header "content-type" contains "application/json" jsonpath "$.did" exists jsonpath "$.availableUserDomains" exists jsonpath "$.inviteCodeRequired" == false -jsonpath "$.links.privacyPolicy" exists -jsonpath "$.links.termsOfService" exists +jsonpath "$.phoneVerificationRequired" == false +jsonpath "$.links" exists +jsonpath "$.contact" exists POST {{base_url}}/xrpc/com.atproto.server.describeServer HTTP 400 diff --git a/test/tempest_web/controllers/xrpc_controller_test.exs b/test/tempest_web/controllers/xrpc_controller_test.exs index 82c19ec..9824da2 100644 --- a/test/tempest_web/controllers/xrpc_controller_test.exs +++ b/test/tempest_web/controllers/xrpc_controller_test.exs @@ -10,8 +10,12 @@ defmodule TempestWeb.XrpcControllerTest do assert response["did"] == "did:web:localhost" assert response["availableUserDomains"] == [".localhost"] assert response["inviteCodeRequired"] == false - assert response["links"]["privacyPolicy"] == nil - assert response["links"]["termsOfService"] == nil + assert response["phoneVerificationRequired"] == false + assert response["links"] == %{} + assert response["contact"] == %{} + refute Map.has_key?(response["links"], "privacyPolicy") + refute Map.has_key?(response["links"], "termsOfService") + refute Map.has_key?(response["contact"], "email") end test "XRPC preflight permits browser ATProto client headers", %{conn: conn} do