Fix /admin/accounts/:account_id/statuses/:id for edited posts with media attachments (#30819)

This commit is contained in:
KMY 2024-07-05 06:56:14 +09:00
parent ae7ec2bbd9
commit f3ac508cf7
3 changed files with 16 additions and 12 deletions

View file

@ -44,6 +44,11 @@ describe Admin::StatusesController do
describe 'GET #show' do
before do
status.media_attachments << Fabricate(:media_attachment, type: :image, account: status.account)
status.save!
status.snapshot!(at_time: status.created_at, rate_limit: false)
status.update!(text: 'Hello, this is an edited post')
status.snapshot!(rate_limit: false)
get :show, params: { account_id: account.id, id: status.id }
end