Skip to content

Commit d174998

Browse files
committed
12178 Fix code style violations
1 parent 26d1798 commit d174998

File tree

2 files changed

+44
-9
lines changed

2 files changed

+44
-9
lines changed

app/code/Magento/Config/Console/Command/ConfigSet/ProcessorFacade.php

Lines changed: 9 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -108,7 +108,6 @@ public function process($path, $value, $scope, $scopeCode, $lock)
108108
return $this->processWithLockTarget($path, $value, $scope, $scopeCode, $lock);
109109
}
110110

111-
112111
/**
113112
* Processes config:set command with the option to set a target file.
114113
*
@@ -121,8 +120,14 @@ public function process($path, $value, $scope, $scopeCode, $lock)
121120
* @return string Processor response message
122121
* @throws ValidatorException If some validation is wrong
123122
*/
124-
public function processWithLockTarget($path, $value, $scope, $scopeCode, $lock, $lockTarget = ConfigFilePool::APP_ENV)
125-
{
123+
public function processWithLockTarget(
124+
$path,
125+
$value,
126+
$scope,
127+
$scopeCode,
128+
$lock,
129+
$lockTarget = ConfigFilePool::APP_ENV
130+
) {
126131
try {
127132
$this->scopeValidator->isValid($scope, $scopeCode);
128133
$this->pathValidator->validate($path);
@@ -158,4 +163,4 @@ public function processWithLockTarget($path, $value, $scope, $scopeCode, $lock,
158163

159164
return $message;
160165
}
161-
}
166+
}

app/code/Magento/Config/Test/Unit/Console/Command/ConfigSet/ProcessorFacadeTest.php

Lines changed: 35 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -123,7 +123,13 @@ public function testProcess()
123123

124124
$this->assertSame(
125125
'Value was saved.',
126-
$this->model->processWithLockTarget('test/test/test', 'test', ScopeConfigInterface::SCOPE_TYPE_DEFAULT, null, false)
126+
$this->model->processWithLockTarget(
127+
'test/test/test',
128+
'test',
129+
ScopeConfigInterface::SCOPE_TYPE_DEFAULT,
130+
null,
131+
false
132+
)
127133
);
128134
}
129135

@@ -139,7 +145,13 @@ public function testProcessWithValidatorException(LocalizedException $exception)
139145
->method('isValid')
140146
->willThrowException($exception);
141147

142-
$this->model->processWithLockTarget('test/test/test', 'test', ScopeConfigInterface::SCOPE_TYPE_DEFAULT, null, false);
148+
$this->model->processWithLockTarget(
149+
'test/test/test',
150+
'test',
151+
ScopeConfigInterface::SCOPE_TYPE_DEFAULT,
152+
null,
153+
false
154+
);
143155
}
144156

145157
/**
@@ -174,7 +186,13 @@ public function testProcessWithConfigurationMismatchException()
174186
$this->configMock->expects($this->never())
175187
->method('clean');
176188

177-
$this->model->processWithLockTarget('test/test/test', 'test', ScopeConfigInterface::SCOPE_TYPE_DEFAULT, null, false);
189+
$this->model->processWithLockTarget(
190+
'test/test/test',
191+
'test',
192+
ScopeConfigInterface::SCOPE_TYPE_DEFAULT,
193+
null,
194+
false
195+
);
178196
}
179197

180198
/**
@@ -200,7 +218,13 @@ public function testProcessWithCouldNotSaveException()
200218
$this->configMock->expects($this->never())
201219
->method('clean');
202220

203-
$this->model->processWithLockTarget('test/test/test', 'test', ScopeConfigInterface::SCOPE_TYPE_DEFAULT, null, false);
221+
$this->model->processWithLockTarget(
222+
'test/test/test',
223+
'test',
224+
ScopeConfigInterface::SCOPE_TYPE_DEFAULT,
225+
null,
226+
false
227+
);
204228
}
205229

206230
public function testExecuteLockEnv()
@@ -220,7 +244,13 @@ public function testExecuteLockEnv()
220244

221245
$this->assertSame(
222246
'Value was saved in app/etc/env.php and locked.',
223-
$this->model->processWithLockTarget('test/test/test', 'test', ScopeConfigInterface::SCOPE_TYPE_DEFAULT, null, true)
247+
$this->model->processWithLockTarget(
248+
'test/test/test',
249+
'test',
250+
ScopeConfigInterface::SCOPE_TYPE_DEFAULT,
251+
null,
252+
true
253+
)
224254
);
225255
}
226256

0 commit comments

Comments
 (0)