Sha256: 3d50946ec75c35b93c2e0d9cfc3798c1f95753df2114f7ba8f57b3b19a5e5070
Contents?: true
Size: 526 Bytes
Versions: 1
Compression:
Stored size: 526 Bytes
Contents
require 'test_helper' class TestRandom < ActiveSupport::TestCase include Challah should "be able to provide a random string from ActiveSupport" do result = Random.token(10) assert_not_nil result assert_equal 10, result.size end should "be able to provide a random string without ActiveSupport" do Challah::Random.stubs(:secure_random?).returns(false) SecureRandom.expects(:hex).never result = Challah::Random.token(10) assert_not_nil result assert_equal 10, result.size end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
challah-1.1.1 | test/services/random_test.rb |