Class: TestUtils
- Inherits:
-
Minitest::Test
- Object
- Minitest::Test
- TestUtils
- Defined in:
- lib/authing_ruby/test/mini_test/TestUtils.rb
Instance Method Summary collapse
Instance Method Details
#test_hash_each ⇒ Object
23 24 25 26 27 28 29 30 31 32 33 |
# File 'lib/authing_ruby/test/mini_test/TestUtils.rb', line 23 def test_hash_each hash = { a:1, b:2, } hash.each do |key, value| puts "key: #{key}" puts "value: #{value}" puts "---" end end |
#test_randomNumberString ⇒ Object
18 19 20 21 |
# File 'lib/authing_ruby/test/mini_test/TestUtils.rb', line 18 def test_randomNumberString random = AuthingRuby::Utils.randomNumberString(10) assert(random.length == 10) end |
#test_randomString ⇒ Object
测试生成随机字符串
13 14 15 16 |
# File 'lib/authing_ruby/test/mini_test/TestUtils.rb', line 13 def test_randomString random = AuthingRuby::Utils.generateRandomString(43) assert(random.length == 43) end |