Merge remote-tracking branch 'parent/main' into upstream-20240524

This commit is contained in:
KMY 2024-05-24 08:33:49 +09:00
commit c546939a40
213 changed files with 2260 additions and 986 deletions

View file

@ -53,11 +53,32 @@ RSpec.describe Admin::AccountsController do
describe 'GET #show' do
let(:current_user) { Fabricate(:user, role: UserRole.find_by(name: 'Admin')) }
let(:account) { Fabricate(:account) }
it 'returns http success' do
get :show, params: { id: account.id }
expect(response).to have_http_status(200)
context 'with a remote account' do
let(:account) { Fabricate(:account, domain: 'example.com') }
it 'returns http success' do
get :show, params: { id: account.id }
expect(response).to have_http_status(200)
end
end
context 'with a local account' do
let(:account) { Fabricate(:account, domain: nil) }
it 'returns http success' do
get :show, params: { id: account.id }
expect(response).to have_http_status(200)
end
end
context 'with a local deleted account' do
let(:account) { Fabricate(:account, domain: nil, user: nil) }
it 'returns http success' do
get :show, params: { id: account.id }
expect(response).to have_http_status(200)
end
end
end