tests/staticpress/content/base_test.rb in staticpress-0.4.0 vs tests/staticpress/content/base_test.rb in staticpress-0.5.0
- old
+ new
@@ -11,11 +11,11 @@
class ContentBaseTest < TestCase
let(:category) { Staticpress::Content::Category.new :name => 'programming' }
let(:category_1) { Staticpress::Content::Category.new(:name => 'programming', :number => '1') }
let(:category_2) { Staticpress::Content::Category.new(:name => 'programming', :number => '2') }
- let(:index) { Staticpress::Content::Index.new :number => 1 }
+ let(:index) { Staticpress::Content::Index.new }
let(:index_2) { Staticpress::Content::Index.new :number => 2 }
let(:page) { Staticpress::Content::Page.new(:slug => 'about') }
let(:second_page) { Staticpress::Content::Page.new :slug => 'contact' }
let(:page_root) { Staticpress::Content::Page.new :slug => '' }
@@ -55,9 +55,10 @@
assert_operator asset_style, :==, Staticpress::Content::Theme.new(:theme => 'test_theme', :asset_type => 'styles', :slug => 'all')
refute_operator asset_style, :==, nil
refute_operator Staticpress::Content::Category.new(:name => 'programming'), :==, Staticpress::Content::Tag.new(:name => 'programming')
+ refute_operator Staticpress::Content::Tag.new(:name => 'charlotte'), :==, Staticpress::Content::Category.new(:name => 'charlotte')
end
def test_content_type
assert_equal 'text/html', page.content_type
assert_equal 'text/css', style_2.content_type