mirror of
https://github.com/discourse/discourse.git
synced 2025-05-22 22:43:33 +08:00
track incoming links, amend share link to include user
fix pm styling
This commit is contained in:
@ -3,6 +3,15 @@ require 'spec_helper'
|
||||
describe PostsController do
|
||||
|
||||
|
||||
describe 'short_link' do
|
||||
it 'logs the incoming link once' do
|
||||
IncomingLink.expects(:add).once.returns(true)
|
||||
p = Fabricate(:post)
|
||||
get :short_link, post_id: p.id, user_id: 999
|
||||
response.should be_redirect
|
||||
end
|
||||
end
|
||||
|
||||
describe 'show' do
|
||||
|
||||
let(:post) { Fabricate(:post, user: log_in) }
|
||||
|
Reference in New Issue
Block a user