From 32223863a51472d929c57d22dbffc5d9c9fafa79 Mon Sep 17 00:00:00 2001 From: Claire Date: Tue, 21 May 2024 15:17:34 +0200 Subject: [PATCH 1/3] Add coverage to `/admin/accounts/:id` (#30386) --- .../admin/accounts_controller_spec.rb | 29 ++++++++++++++++--- 1 file changed, 25 insertions(+), 4 deletions(-) diff --git a/spec/controllers/admin/accounts_controller_spec.rb b/spec/controllers/admin/accounts_controller_spec.rb index b90bb414b0..f241d261b1 100644 --- a/spec/controllers/admin/accounts_controller_spec.rb +++ b/spec/controllers/admin/accounts_controller_spec.rb @@ -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 From cd0c5479362260082dbe1cbc42e364017853bbfc Mon Sep 17 00:00:00 2001 From: David Lapshin Date: Tue, 21 May 2024 18:24:51 +0300 Subject: [PATCH 2/3] Fix announcements icon rotating like settings one (#30388) --- app/javascript/styles/mastodon/components.scss | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/app/javascript/styles/mastodon/components.scss b/app/javascript/styles/mastodon/components.scss index f377eed95c..859c6e3267 100644 --- a/app/javascript/styles/mastodon/components.scss +++ b/app/javascript/styles/mastodon/components.scss @@ -4372,7 +4372,7 @@ a.status-card { color: $primary-text-color; } - .icon { + .icon-sliders { transform: rotate(60deg); } } @@ -4383,7 +4383,7 @@ a.status-card { } } -.no-reduce-motion .column-header__button .icon { +.no-reduce-motion .column-header__button .icon-sliders { transition: transform 150ms ease-in-out; } From dc35563f65e3c843b847c6d58797937200e27233 Mon Sep 17 00:00:00 2001 From: David Lapshin Date: Tue, 21 May 2024 18:24:51 +0300 Subject: [PATCH 3/3] [Glitch] Fix announcements icon rotating like settings one Port cd0c5479362260082dbe1cbc42e364017853bbfc to glitch-soc Signed-off-by: Claire --- app/javascript/flavours/glitch/styles/components.scss | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/app/javascript/flavours/glitch/styles/components.scss b/app/javascript/flavours/glitch/styles/components.scss index 9f102b847e..07b18b2936 100644 --- a/app/javascript/flavours/glitch/styles/components.scss +++ b/app/javascript/flavours/glitch/styles/components.scss @@ -4609,7 +4609,7 @@ a.status-card { color: $primary-text-color; } - .icon { + .icon-sliders { transform: rotate(60deg); } } @@ -4659,7 +4659,7 @@ a.status-card { padding: 0; } -.no-reduce-motion .column-header__button .icon { +.no-reduce-motion .column-header__button .icon-sliders { transition: transform 150ms ease-in-out; }