Skip to content

Commit

Permalink
update dependencies, fix unit tests
Browse files Browse the repository at this point in the history
  • Loading branch information
dakorpar committed Oct 10, 2017
1 parent 7550483 commit b832cb6
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 8 deletions.
3 changes: 1 addition & 2 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
},
"require": {
"nette/di": "~2.4",
"nette/php-generator": "~2.3",
"nette/php-generator": "~2.6",

"kdyby/annotations": "^2.1",
"symfony/property-access": "~3.2"
Expand All @@ -36,7 +36,6 @@
"nette/http": "~2.4",
"nette/mail": "~2.4",
"nette/neon": "~2.4",
"nette/php-generator": "~2.3",
"nette/reflection": "~2.4",
"nette/robot-loader": "~2.4",
"nette/safe-stream": "~2.3",
Expand Down
12 changes: 6 additions & 6 deletions tests/KdybyTests/Aop/Criteria.phpt
Original file line number Diff line number Diff line change
Expand Up @@ -160,7 +160,7 @@ class CriteriaTest extends Tester\TestCase
{
$criteria = Criteria::create()->where('this.foo.bar', Criteria::EQ, new Code\PhpLiteral('TRUE'));
Assert::same(
"(Criteria::compare(PropertyAccess::createPropertyAccessor()->getValue(\$this, 'foo.bar'), '==', TRUE))",
"(Criteria::compare(PropertyAccess::createPropertyAccessor()->getValue(\$this, 'foo.bar'), '==', true))",
(string) $criteria->serialize(new Nette\DI\ContainerBuilder())
);
}
Expand All @@ -171,7 +171,7 @@ class CriteriaTest extends Tester\TestCase
{
$criteria = Criteria::create()->where('$arg', Criteria::EQ, new Code\PhpLiteral('TRUE'));
Assert::same(
"(Criteria::compare(\$arg, '==', TRUE))",
"(Criteria::compare(\$arg, '==', true))",
(string) $criteria->serialize(new Nette\DI\ContainerBuilder())
);
}
Expand All @@ -184,7 +184,7 @@ class CriteriaTest extends Tester\TestCase
$builder->parameters['foo']['bar'] = 'complicated value!';
$criteria = Criteria::create()->where('%foo.bar%', Criteria::EQ, new Code\PhpLiteral('TRUE'));
Assert::same(
"(Criteria::compare('complicated value!', '==', TRUE))",
"(Criteria::compare('complicated value!', '==', true))",
(string) $criteria->serialize($builder)
);
}
Expand All @@ -195,7 +195,7 @@ class CriteriaTest extends Tester\TestCase
{
$criteria = Criteria::create()->where('context.foo.bar', Criteria::EQ, new Code\PhpLiteral('TRUE'));
Assert::same(
"(Criteria::compare(PropertyAccess::createPropertyAccessor()->getValue(\$this->_kdyby_aopContainer->getService('foo'), 'bar'), '==', TRUE))",
"(Criteria::compare(PropertyAccess::createPropertyAccessor()->getValue(\$this->_kdyby_aopContainer->getService('foo'), 'bar'), '==', true))",
(string) $criteria->serialize(new Nette\DI\ContainerBuilder())
);
}
Expand All @@ -206,13 +206,13 @@ class CriteriaTest extends Tester\TestCase
{
$criteria = Criteria::create()->where('context.stdClass.bar', Criteria::EQ, new Code\PhpLiteral('TRUE'));
Assert::match(
"(Criteria::compare(PropertyAccess::createPropertyAccessor()->getValue(\$this->_kdyby_aopContainer->getByType('stdClass'), 'bar'), '==', TRUE))",
"(Criteria::compare(PropertyAccess::createPropertyAccessor()->getValue(\$this->_kdyby_aopContainer->getByType('stdClass'), 'bar'), '==', true))",
(string) $criteria->serialize(new Nette\DI\ContainerBuilder())
);

$criteria = Criteria::create()->where('context.KdybyTests\Aop\CriteriaTest.bar', Criteria::EQ, new Code\PhpLiteral('TRUE'));
Assert::match(
"(Criteria::compare(PropertyAccess::createPropertyAccessor()->getValue(\$this->_kdyby_aopContainer->getByType('KdybyTests%a%Aop%a%CriteriaTest'), 'bar'), '==', TRUE))",
"(Criteria::compare(PropertyAccess::createPropertyAccessor()->getValue(\$this->_kdyby_aopContainer->getByType('KdybyTests%a%Aop%a%CriteriaTest'), 'bar'), '==', true))",
(string) $criteria->serialize(new Nette\DI\ContainerBuilder())
);
}
Expand Down

0 comments on commit b832cb6

Please sign in to comment.