Slugs should not have 'dot' in them.
This commit is contained in:
parent
2798e15481
commit
22d55cf0e0
@ -146,7 +146,7 @@ describe Locomotive::ContentEntry do
|
||||
|
||||
it 'removes dots' do
|
||||
@content_entry.title = "my.test"; @content_entry.send(:set_slug)
|
||||
@content_entry._permalink.should == 'my-dot-test'
|
||||
@content_entry._permalink.should == 'my-test'
|
||||
end
|
||||
|
||||
it 'accepts non-latin chars' do
|
||||
|
@ -102,11 +102,11 @@ describe Locomotive::Page do
|
||||
it 'should have normalized slug' do
|
||||
page = FactoryGirl.build(:page, :slug => ' Valid ité.html ')
|
||||
page.valid?
|
||||
page.slug.should == 'valid-ite-dot-html'
|
||||
page.slug.should == 'valid-ite-html'
|
||||
|
||||
page = FactoryGirl.build(:page, :title => ' Valid ité.html ', :slug => nil, :site => page.site)
|
||||
page.should be_valid
|
||||
page.slug.should == 'valid-ite-dot-html'
|
||||
page.slug.should == 'valid-ite-html'
|
||||
end
|
||||
|
||||
it 'has no cache strategy' do
|
||||
|
Loading…
Reference in New Issue
Block a user