store the slug as the title is, only sanitize the slug

and prettify code
This commit is contained in:
Erick Guan
2015-05-04 19:48:37 +08:00
committed by fantasticfears
parent b772ff6e13
commit a48dd1cc28
12 changed files with 45 additions and 45 deletions

View File

@@ -209,8 +209,8 @@ describe Category do
end
it "creates a slug" do
expect(@category.slug).to eq("%E6%B5%8B%E8%AF%95")
expect(@category.slug_for_url).to eq("%E6%B5%8B%E8%AF%95")
expect(@category.slug).to eq("测试")
expect(@category.slug_for_url).to eq("测试")
end
end
end