Guest User

Untitled

a guest
Sep 20th, 2018
87
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.13 KB | None | 0 0
  1. ### CODE
  2.  
  3. ```ruby
  4. require 'minitest/autorun'
  5.  
  6. describe ArrayFinder do
  7. describe "create new finder" do
  8. it "sets collection to empty" do
  9. collection = %w{1 2 3 4 5}
  10. finder = ArrayFinder.new(collection)
  11.  
  12. finder.collection.must_equal collection
  13. end
  14. end
  15. end
  16. ```
  17.  
  18. ### RBX O/P
  19.  
  20. ```
  21. ९ ruby -X19 try_errors.rb
  22. An exception occurred running try_errors.rb
  23. Missing or uninitialized constant: Object::ArrayFinder (NameError)
  24.  
  25. Backtrace:
  26. Module(Class)#const_missing at kernel/common/module.rb:468
  27. Object#__script__ at try_errors.rb:3
  28. Rubinius::CodeLoader#load_script at kernel/delta/codeloader.rb:67
  29. Rubinius::CodeLoader.load_script at kernel/delta/codeloader.rb:109
  30. Rubinius::Loader#script at kernel/loader.rb:632
  31. Rubinius::Loader#main at kernel/loader.rb:836
  32. Run options: --seed 1793
  33.  
  34. # Running tests:
  35.  
  36.  
  37.  
  38. Finished tests in 0.000613s, 0.0000 tests/s, 0.0000 assertions/s.
  39.  
  40. 0 tests, 0 assertions, 0 failures, 0 errors, 0 skips
  41. ```
  42.  
  43. ### JRuby O/P
  44.  
  45. ```
  46. NameError: uninitialized constant ArrayFinder
  47. const_missing at org/jruby/RubyModule.java:2642
  48. (root) at try_errors.rb:3
  49. ```
Add Comment
Please, Sign In to add comment