0
0
Fork 0

Fix RSpec/ContextWording cop (#24739)

This commit is contained in:
Matt Jankowski 2023-05-03 23:49:08 -04:00 committed by GitHub
parent cf18cc2891
commit 710745e16b
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
105 changed files with 559 additions and 668 deletions

View file

@ -50,7 +50,7 @@ describe Settings::ApplicationsController do
end
describe 'POST #create' do
context 'success (passed scopes as a String)' do
context 'when success (passed scopes as a String)' do
def call_create
post :create, params: {
doorkeeper_application: {
@ -72,7 +72,7 @@ describe Settings::ApplicationsController do
end
end
context 'success (passed scopes as an Array)' do
context 'when success (passed scopes as an Array)' do
def call_create
post :create, params: {
doorkeeper_application: {
@ -94,7 +94,7 @@ describe Settings::ApplicationsController do
end
end
context 'failure' do
context 'with failure request' do
before do
post :create, params: {
doorkeeper_application: {
@ -117,7 +117,7 @@ describe Settings::ApplicationsController do
end
describe 'PATCH #update' do
context 'success' do
context 'when success' do
let(:opts) do
{
website: 'https://foo.bar/',
@ -142,7 +142,7 @@ describe Settings::ApplicationsController do
end
end
context 'failure' do
context 'with failure request' do
before do
patch :update, params: {
id: app.id,

View file

@ -275,7 +275,7 @@ describe Settings::TwoFactorAuthentication::WebauthnCredentialsController do
end
context 'when user have not enabled webauthn' do
context 'creation succeeds' do
context 'when creation succeeds' do
it 'creates a webauthn credential' do
@controller.session[:webauthn_challenge] = challenge