Re-record fixture

And document how to run it.
This commit is contained in:
David Cook
2025-02-26 15:27:43 +11:00
committed by Maikel Linke
parent 428bcc8988
commit 75dcee12a8
3 changed files with 24 additions and 355 deletions

View File

@@ -16,6 +16,10 @@ STRIPE_PUBLIC_TEST_API_KEY="bogus_stripe_publishable_key"
SITE_URL="test.host"
# OIDC Settings for DFC authentication
# Find secrets in BitWarden.
# To get a refresh token: log into the OIDC provider, connect your OFN user to it at /admin/oidc_settings, then copy the token from the database:
# ./bin/rails runner 'puts "OPENID_REFRESH_TOKEN=\"#{OidcAccount.last.refresh_token}\""'
OPENID_APP_ID="test-provider"
OPENID_APP_SECRET="dummy-openid-app-secret-token"
OPENID_REFRESH_TOKEN="dummy-refresh-token"

View File

@@ -6,6 +6,7 @@ FactoryBot.define do
uid { user&.email || generate(:random_email) }
# This is a live test account authenticated via Les Communes.
# See .env.test for tips on connecting the account for recording VCR cassettes.
factory :testdfc_account do
uid { "testdfc@protonmail.com" }
refresh_token { ENV.fetch("OPENID_REFRESH_TOKEN") }