Skip to content

Commit ad721ed

Browse files
committed
Fix static test failures
1 parent e00375a commit ad721ed

File tree

15 files changed

+37
-26
lines changed

15 files changed

+37
-26
lines changed

app/code/Magento/Tax/Block/Adminhtml/Rate/Form.php

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@
2525
*/
2626
class Form extends \Magento\Backend\Block\Widget\Form\Generic
2727
{
28-
const FORM_ELEMENT_ID = 'rate-form';
28+
public const FORM_ELEMENT_ID = 'rate-form';
2929

3030
/**
3131
* @var null
@@ -38,8 +38,6 @@ class Form extends \Magento\Backend\Block\Widget\Form\Generic
3838
protected $_template = 'Magento_Tax::rate/form.phtml';
3939

4040
/**
41-
* Tax data
42-
*
4341
* @var \Magento\Tax\Helper\Data|null
4442
*/
4543
protected $_taxData = null;

app/code/Magento/Tax/Block/Adminhtml/Rate/Title.php

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -90,6 +90,8 @@ public function getTitles()
9090
}
9191

9292
/**
93+
* Return all the stores
94+
*
9395
* @return mixed
9496
*/
9597
public function getStores()

app/code/Magento/Tax/Block/Adminhtml/Rate/Title/Fieldset.php

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -35,6 +35,8 @@ public function __construct(
3535
}
3636

3737
/**
38+
* Get title formatted in HTML
39+
*
3840
* @return string
3941
*/
4042
public function getBasicChildrenHtml()

app/code/Magento/Tax/Block/Adminhtml/Rate/Toolbar/Add.php

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,7 @@ public function __construct(
4848
}
4949

5050
/**
51-
* {$@inheritdoc}
51+
* @inheritDoc
5252
*/
5353
public function addButton($buttonId, $data, $level = 0, $sortOrder = 0, $region = 'toolbar')
5454
{
@@ -57,7 +57,7 @@ public function addButton($buttonId, $data, $level = 0, $sortOrder = 0, $region
5757
}
5858

5959
/**
60-
* {$@inheritdoc}
60+
* @inheritDoc
6161
*/
6262
public function removeButton($buttonId)
6363
{
@@ -66,6 +66,8 @@ public function removeButton($buttonId)
6666
}
6767

6868
/**
69+
* Prepare the layout
70+
*
6971
* @return $this
7072
*/
7173
protected function _prepareLayout()
@@ -84,7 +86,7 @@ protected function _prepareLayout()
8486
}
8587

8688
/**
87-
* {$@inheritdoc}
89+
* @inheritDoc
8890
*/
8991
public function updateButton($buttonId, $key, $data)
9092
{
@@ -93,7 +95,7 @@ public function updateButton($buttonId, $key, $data)
9395
}
9496

9597
/**
96-
* {$@inheritdoc}
98+
* @inheritDoc
9799
*/
98100
public function canRender(\Magento\Backend\Block\Widget\Button\Item $item)
99101
{

app/code/Magento/Tax/Block/Adminhtml/Rule.php

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,8 @@
1616
class Rule extends \Magento\Backend\Block\Widget\Grid\Container
1717
{
1818
/**
19+
* Initialise the block
20+
*
1921
* @return void
2022
*/
2123
protected function _construct()

app/code/Magento/Tax/Block/Item/Price/Renderer.php

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -105,6 +105,8 @@ public function setZone($zone)
105105
}
106106

107107
/**
108+
* Return the store ID
109+
*
108110
* @return int|null|string
109111
*/
110112
public function getStoreId()
@@ -200,8 +202,7 @@ public function formatPrice($price)
200202
}
201203

202204
/**
203-
* Get item price in display currency or order currency depending
204-
* on item type
205+
* Get item price in display currency or order currency depending on item type
205206
*
206207
* @return float
207208
*/

app/code/Magento/Tax/Controller/Adminhtml/Rule.php

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -19,11 +19,9 @@ abstract class Rule extends \Magento\Backend\App\Action
1919
*
2020
* @see _isAllowed()
2121
*/
22-
const ADMIN_RESOURCE = 'Magento_Tax::manage_tax';
22+
public const ADMIN_RESOURCE = 'Magento_Tax::manage_tax';
2323

2424
/**
25-
* Core registry
26-
*
2725
* @var \Magento\Framework\Registry
2826
*/
2927
protected $_coreRegistry = null;

app/code/Magento/Tax/Controller/Adminhtml/Tax.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ abstract class Tax extends \Magento\Backend\App\Action
1818
*
1919
* @see _isAllowed()
2020
*/
21-
const ADMIN_RESOURCE = 'Magento_Tax::manage_tax';
21+
public const ADMIN_RESOURCE = 'Magento_Tax::manage_tax';
2222

2323
/**
2424
* @var \Magento\Tax\Api\TaxClassRepositoryInterface

app/code/Magento/Tax/Model/Calculation/Rate/Title.php

Lines changed: 12 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -19,11 +19,13 @@ class Title extends \Magento\Framework\Model\AbstractExtensibleModel implements
1919
*
2020
* Tax rate field key.
2121
*/
22-
const KEY_STORE_ID = 'store_id';
23-
const KEY_VALUE_ID = 'value';
22+
public const KEY_STORE_ID = 'store_id';
23+
public const KEY_VALUE_ID = 'value';
2424
/**#@-*/
2525

2626
/**
27+
* Initialise the model
28+
*
2729
* @return void
2830
*/
2931
protected function _construct()
@@ -32,6 +34,8 @@ protected function _construct()
3234
}
3335

3436
/**
37+
* Delete a rate with specified ID
38+
*
3539
* @param int $rateId
3640
* @return $this
3741
*/
@@ -41,17 +45,18 @@ public function deleteByRateId($rateId)
4145
return $this;
4246
}
4347

48+
// @codeCoverageIgnoreStart
49+
4450
/**
45-
* @codeCoverageIgnoreStart
46-
* {@inheritdoc}
51+
* @inheritDoc
4752
*/
4853
public function getStoreId()
4954
{
5055
return $this->getData(self::KEY_STORE_ID);
5156
}
5257

5358
/**
54-
* {@inheritdoc}
59+
* @inheritDoc
5560
*/
5661
public function getValue()
5762
{
@@ -83,7 +88,7 @@ public function setValue($value)
8388
// @codeCoverageIgnoreEnd
8489

8590
/**
86-
* {@inheritdoc}
91+
* @inheritDoc
8792
*
8893
* @return \Magento\Tax\Api\Data\TaxRateTitleExtensionInterface|null
8994
*/
@@ -93,7 +98,7 @@ public function getExtensionAttributes()
9398
}
9499

95100
/**
96-
* {@inheritdoc}
101+
* @inheritDoc
97102
*
98103
* @param \Magento\Tax\Api\Data\TaxRateTitleExtensionInterface $extensionAttributes
99104
* @return $this

app/code/Magento/Tax/Model/ResourceModel/Calculation/Rule/Collection.php

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -168,7 +168,6 @@ public function setClassTypeFilter($type, $id)
168168
break;
169169
default:
170170
throw new \Magento\Framework\Exception\LocalizedException(__('Invalid type supplied'));
171-
break;
172171
}
173172

174173
$this->joinCalculationData('cd');

0 commit comments

Comments
 (0)