Commit 7d7df877 authored by ysksn's avatar ysksn Committed by Eugen Rochko

Add a test for Tag#to_param (#5705)

parent c73a1fb5
......@@ -35,6 +35,13 @@ RSpec.describe Tag, type: :model do
end
end
describe '#to_param' do
it 'returns name' do
tag = Fabricate(:tag, name: 'foo')
expect(tag.to_param).to eq 'foo'
end
end
describe '.search_for' do
it 'finds tag records with matching names' do
tag = Fabricate(:tag, name: "match")
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment