1
0
mirror of https://github.com/ezyang/htmlpurifier.git synced 2025-07-31 19:30:21 +02:00

Fixed reserved words in constants for PHP 7 as per https://www.php.net/manual/en/reserved.other-reserved-words.php (#222)

This commit is contained in:
Darko Hrgovic
2019-07-10 19:24:27 -07:00
committed by Edward Z. Yang
parent a93250f251
commit f03e1a2c48
5 changed files with 28 additions and 28 deletions

View File

@@ -15,12 +15,12 @@ class HTMLPurifier_ConfigSchemaTest extends HTMLPurifier_Harness
$this->schema->add('Car.Seats', 5, 'int', false);
$this->assertIdentical($this->schema->defaults['Car.Seats'], 5);
$this->assertIdentical($this->schema->info['Car.Seats']->type, HTMLPurifier_VarParser::INT);
$this->assertIdentical($this->schema->info['Car.Seats']->type, HTMLPurifier_VarParser::C_INT);
$this->schema->add('Car.Age', null, 'int', true);
$this->assertIdentical($this->schema->defaults['Car.Age'], null);
$this->assertIdentical($this->schema->info['Car.Age']->type, HTMLPurifier_VarParser::INT);
$this->assertIdentical($this->schema->info['Car.Age']->type, HTMLPurifier_VarParser::C_INT);
}
@@ -35,7 +35,7 @@ class HTMLPurifier_ConfigSchemaTest extends HTMLPurifier_Harness
);
$this->assertIdentical($this->schema->defaults['QuantumNumber.Difficulty'], null);
$this->assertIdentical($this->schema->info['QuantumNumber.Difficulty']->type, HTMLPurifier_VarParser::STRING);
$this->assertIdentical($this->schema->info['QuantumNumber.Difficulty']->type, HTMLPurifier_VarParser::C_STRING);
$this->assertIdentical($this->schema->info['QuantumNumber.Difficulty']->allow_null, true);
$this->assertIdentical($this->schema->info['QuantumNumber.Difficulty']->allowed,
array(
@@ -70,7 +70,7 @@ class HTMLPurifier_ConfigSchemaTest extends HTMLPurifier_Harness
);
$this->assertIdentical($this->schema->defaults['Abbrev.HTH'], 'Happy to Help');
$this->assertIdentical($this->schema->info['Abbrev.HTH']->type, HTMLPurifier_VarParser::STRING);
$this->assertIdentical($this->schema->info['Abbrev.HTH']->type, HTMLPurifier_VarParser::C_STRING);
$this->assertIdentical($this->schema->info['Abbrev.HTH']->allowed,
array(
'Happy to Help' => true,