Definition at line 9 of file IsNumericConstraintTest.php.
◆ setUp()
IsNumericConstraintTest::setUp |
( |
| ) |
|
Definition at line 11 of file IsNumericConstraintTest.php.
13 $this->df =
new Data\Factory();
14 $this->lng = $this->createMock(\ilLanguage::class);
15 $this->f =
new Validation\Factory($this->df, $this->lng);
17 $this->c = $this->f->isNumeric();
◆ testAccepts1()
IsNumericConstraintTest::testAccepts1 |
( |
| ) |
|
◆ testAccepts2()
IsNumericConstraintTest::testAccepts2 |
( |
| ) |
|
◆ testAccepts3()
IsNumericConstraintTest::testAccepts3 |
( |
| ) |
|
◆ testAccepts4()
IsNumericConstraintTest::testAccepts4 |
( |
| ) |
|
◆ testAccepts5()
IsNumericConstraintTest::testAccepts5 |
( |
| ) |
|
◆ testAccepts6()
IsNumericConstraintTest::testAccepts6 |
( |
| ) |
|
◆ testAccepts7()
IsNumericConstraintTest::testAccepts7 |
( |
| ) |
|
◆ testAccepts8()
IsNumericConstraintTest::testAccepts8 |
( |
| ) |
|
◆ testCheckFails()
IsNumericConstraintTest::testCheckFails |
( |
| ) |
|
◆ testCheckSucceed()
IsNumericConstraintTest::testCheckSucceed |
( |
| ) |
|
◆ testNoProblemWith()
IsNumericConstraintTest::testNoProblemWith |
( |
| ) |
|
◆ testNotAccepts1()
IsNumericConstraintTest::testNotAccepts1 |
( |
| ) |
|
◆ testNotAccepts2()
IsNumericConstraintTest::testNotAccepts2 |
( |
| ) |
|
◆ testProblemWith()
IsNumericConstraintTest::testProblemWith |
( |
| ) |
|
Definition at line 87 of file IsNumericConstraintTest.php.
References Sabre\Event\once().
90 ->expects($this->
once())
95 $this->assertEquals(
"-aa-", $this->c->problemWith(
"aa"));
once($eventName, callable $callBack, $priority=100)
Subscribe to an event exactly once.
◆ testRestrictError()
IsNumericConstraintTest::testRestrictError |
( |
| ) |
|
Definition at line 114 of file IsNumericConstraintTest.php.
References $res.
116 $error = $this->df->error(
"error");
118 $res = $this->c->restrict($error);
119 $this->assertSame($error,
$res);
foreach($_POST as $key=> $value) $res
◆ testRestrictNotOk()
IsNumericConstraintTest::testRestrictNotOk |
( |
| ) |
|
Definition at line 106 of file IsNumericConstraintTest.php.
References $res.
108 $not_ok = $this->df->ok(
"");
110 $res = $this->c->restrict($not_ok);
111 $this->assertFalse(
$res->isOk());
foreach($_POST as $key=> $value) $res
◆ testRestrictOk()
IsNumericConstraintTest::testRestrictOk |
( |
| ) |
|
◆ testWithProblemBuilder()
IsNumericConstraintTest::testWithProblemBuilder |
( |
| ) |
|
Definition at line 122 of file IsNumericConstraintTest.php.
124 $new_c = $this->c->withProblemBuilder(
function () {
125 return "This was a fault";
127 $this->assertEquals(
"This was a fault", $new_c->problemWith(
""));
The documentation for this class was generated from the following file: