aboutsummaryrefslogtreecommitdiffstats
path: root/test/verified_key_with_expiration_test.rb
blob: ac605a95e9d5e950926c2aae83db401d7bfb72b0 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
require "test_helper"
require "active_support/core_ext/securerandom"

class ActiveFile::VerifiedKeyWithExpirationTest < ActiveSupport::TestCase
  FIXTURE_KEY = SecureRandom.base58(24)

  test "without expiration" do
    encoded_key = ActiveFile::VerifiedKeyWithExpiration.encode(FIXTURE_KEY)
    assert_equal FIXTURE_KEY, ActiveFile::VerifiedKeyWithExpiration.decode(encoded_key)
  end
end