function NumberTest::testValidStepOffset
Same name in other branches
- 9 core/tests/Drupal/Tests/Component/Utility/NumberTest.php \Drupal\Tests\Component\Utility\NumberTest::testValidStepOffset()
- 8.9.x core/tests/Drupal/Tests/Component/Utility/NumberTest.php \Drupal\Tests\Component\Utility\NumberTest::testValidStepOffset()
- 10 core/tests/Drupal/Tests/Component/Utility/NumberTest.php \Drupal\Tests\Component\Utility\NumberTest::testValidStepOffset()
Tests Number::validStep() with offset.
@dataProvider providerTestValidStepOffset @covers ::validStep
Parameters
numeric $value: The value argument for Number::validStep().
numeric $step: The step argument for Number::validStep().
numeric $offset: The offset argument for Number::validStep().
bool $expected: Expected return value from Number::validStep().
File
-
core/
tests/ Drupal/ Tests/ Component/ Utility/ NumberTest.php, line 54
Class
- NumberTest
- Tests number manipulation utilities.
Namespace
Drupal\Tests\Component\UtilityCode
public function testValidStepOffset($value, $step, $offset, $expected) : void {
$return = Number::validStep($value, $step, $offset);
$this->assertEquals($expected, $return);
}
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.