Welcome to mirror list, hosted at ThFree Co, Russian Federation.

token_with_ivs.rb « factories « spec - gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
blob: 68989f6c5bc6955035ea29dd2ea0d73e89dfb329 (plain)
1
2
3
4
5
6
7
8
9
# frozen_string_literal: true

FactoryBot.define do
  factory :token_with_iv do
    hashed_token { ::Digest::SHA256.digest(SecureRandom.hex(50)) }
    iv { ::Digest::SHA256.digest(SecureRandom.hex(50)) }
    hashed_plaintext_token { ::Digest::SHA256.digest(SecureRandom.hex(50)) }
  end
end