Sha256: d34205cc9ae1f31ddd48516615663d7d4fec03299416e0bc0d8f2f57c0a73dbe
Contents?: true
Size: 567 Bytes
Versions: 1
Compression:
Stored size: 567 Bytes
Contents
require 'spec_helper' describe Post do context 'when content is valid' do let(:post) { Post.new(content: 'valid content') } it 'should be valid' do expect(post).to be_valid end end context 'when content equals profane word' do let(:post) { Post.new(content: 'foo') } it 'should not be valid' do expect(post).not_to be_valid end end context 'when content includes profane word' do let(:post) { Post.new(content: 'foobarbaz') } it 'should not be valid' do expect(post).not_to be_valid end end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
antivirus-0.0.2 | spec/models/post_spec.rb |