Skip to content

Commit d2bc7fb

Browse files
Merge branch '3.1'
* 3.1: [PropertyAccess] Fix for PHP 7.0.7 [Yaml] search for colons in strings only bumped Symfony version to 3.1.0 updated VERSION for 3.1.0-RC1 updated CHANGELOG for 3.1.0-RC1 fixed PHP 5.3 compat in tests
2 parents b94975b + 9aa8d62 commit d2bc7fb

File tree

1 file changed

+9
-3
lines changed

1 file changed

+9
-3
lines changed

Tests/PropertyAccessorTest.php

Lines changed: 9 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -242,7 +242,9 @@ public function testSetValueThrowsNoExceptionIfIndexNotFoundAndIndexExceptionsEn
242242
*/
243243
public function testSetValueThrowsExceptionIfNotArrayAccess()
244244
{
245-
$this->propertyAccessor->setValue(new \stdClass(), '[index]', 'Updated');
245+
$object = new \stdClass();
246+
247+
$this->propertyAccessor->setValue($object, '[index]', 'Updated');
246248
}
247249

248250
public function testSetValueUpdatesMagicSet()
@@ -259,7 +261,9 @@ public function testSetValueUpdatesMagicSet()
259261
*/
260262
public function testSetValueThrowsExceptionIfThereAreMissingParameters()
261263
{
262-
$this->propertyAccessor->setValue(new TestClass('Bernhard'), 'publicAccessorWithMoreRequiredParameters', 'Updated');
264+
$object = new TestClass('Bernhard');
265+
266+
$this->propertyAccessor->setValue($object, 'publicAccessorWithMoreRequiredParameters', 'Updated');
263267
}
264268

265269
/**
@@ -527,7 +531,9 @@ public function testIsWritableForReferenceChainIssue($object, $path, $value)
527531
*/
528532
public function testThrowTypeError()
529533
{
530-
$this->propertyAccessor->setValue(new TypeHinted(), 'date', 'This is a string, \DateTime expected.');
534+
$object = new TypeHinted();
535+
536+
$this->propertyAccessor->setValue($object, 'date', 'This is a string, \DateTime expected.');
531537
}
532538

533539
public function testSetTypeHint()

0 commit comments

Comments
 (0)