From 54c2ebe3ae5b9d77be735a2f87abe5e82c5ee8c5 Mon Sep 17 00:00:00 2001 From: Javier Eguiluz Date: Sat, 23 Dec 2017 16:28:31 +0100 Subject: [PATCH] Reduce the BCrypt cost in tests to run them much faster --- config/packages/test/security.yaml | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/config/packages/test/security.yaml b/config/packages/test/security.yaml index 356fbc002..b949c9480 100644 --- a/config/packages/test/security.yaml +++ b/config/packages/test/security.yaml @@ -1,6 +1,11 @@ # this configuration simplifies testing URLs protected by the security mechanism # See https://symfony.com/doc/current/cookbook/testing/http_authentication.html security: + encoders: + # to make tests much faster, BCrypt cost is changed to its minimum allowed value (4) + # See https://symfony.com/doc/current/reference/configuration/security.html#using-the-bcrypt-password-encoder + App\Entity\User: { algorithm: bcrypt, cost: 4 } + firewalls: main: http_basic: ~