Advertisement
ricardovaltierra

shoulda-matchers omitted's output

Nov 16th, 2020
1,867
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Rails 1.10 KB | None | 0 0
  1. Shoulda matchers omitted on rails_helper
  2.  
  3. # Shoulda::Matchers.configure do |config|
  4. #   config.integrate do |with|
  5. #     with.test_framework :rspec
  6. #     with.library :rails
  7. #   end
  8. # end
  9.  
  10. # task_spec.rb
  11.  
  12. require 'rails_helper'
  13.  
  14. RSpec.describe Task, type: :model do
  15.  
  16.   DatabaseCleaner.start
  17.  
  18.   it "is valid with valid attributes" do
  19.     expect(Task.new).to be_valid
  20.   end
  21.  
  22.   it "is not valid without a name"
  23.   it "is not valid without a description"
  24.   it "is not valid without a completion"
  25. end
  26.  
  27. # Output from command RAILS_ENV=test bundle exec rspec
  28.  
  29. .***
  30.  
  31. Pending: (Failures listed here are expected and do not affect your suite's status)
  32.  
  33.  1) Task is not valid without a name
  34.     # Not yet implemented
  35.     # ./spec/models/task_spec.rb:11
  36.  
  37.  2) Task is not valid without a description
  38.     # Not yet implemented
  39.     # ./spec/models/task_spec.rb:12
  40.  
  41.  3) Task is not valid without a completion
  42.     # Not yet implemented
  43.     # ./spec/models/task_spec.rb:13
  44.  
  45.  
  46. Finished in 0.20954 seconds (files took 0.71481 seconds to load)
  47. 4 examples, 0 failures, 3 pending
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement