Files
jekyll/test/test_wordpressdotcom_migrator.rb
Matt Rogers 8fb4e8fcca Convert slashes in titles to dashes when migrating from WordPress
When a post has a title that contains a slash, such as 'This is my cool
blog post part 1/2', convert the slash to a dash so that the post
filename is created correctly.

Fixes issue #680
2012-12-04 20:45:20 -06:00

10 lines
282 B
Ruby

require 'helper'
require 'jekyll/migrators/wordpressdotcom'
class TestWordpressDotComMigrator < Test::Unit::TestCase
should "clean slashes from slugs" do
test_title = "blogs part 1/2"
assert_equal("blogs-part-1-2", Jekyll::WordpressDotCom.sluggify(test_title))
end
end