device_fabricator.rb 434 B

12345678910
  1. # frozen_string_literal: true
  2. Fabricator(:device) do
  3. access_token { Fabricate.build(:access_token) }
  4. account { Fabricate.build(:account) }
  5. device_id { Faker::Number.number(digits: 5) }
  6. name { Faker::App.name }
  7. fingerprint_key { Base64.strict_encode64(Ed25519::SigningKey.generate.verify_key.to_bytes) }
  8. identity_key { Base64.strict_encode64(Ed25519::SigningKey.generate.verify_key.to_bytes) }
  9. end