Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

update to official Nette\Tester

  • Loading branch information...
commit 473a5f37c65b5f82a5b1a040e5bc0dae52dc07e1 1 parent 3c63e86
@Vrtak-CZ Vrtak-CZ authored
Showing with 311 additions and 194 deletions.
  1. +1 −1  build.xml
  2. +1 −7 composer.json
  3. +6 −4 tests/Nella/Application/PresenterFactoryTest.phpt
  4. +6 −4 tests/Nella/Application/UI/ControlTest.phpt
  5. +6 −4 tests/Nella/Application/UI/PresenterTest.phpt
  6. +6 −4 tests/Nella/Config/ConfiguratorTest.phpt
  7. +5 −3 tests/Nella/Config/Extensions/NellaExtensionTest.phpt
  8. +5 −3 tests/Nella/Console/Config/ExtensionTest.phpt
  9. +4 −3 tests/Nella/Console/LazyRouteTest.phpt
  10. +5 −3 tests/Nella/Doctrine/CacheTest.phpt
  11. +5 −3 tests/Nella/Doctrine/Config/ExtensionTest.phpt
  12. +5 −3 tests/Nella/Doctrine/Config/MigrationsExtensionTest.phpt
  13. +5 −3 tests/Nella/Doctrine/EntityTest.phpt
  14. +5 −3 tests/Nella/Event/Args/ApplicationErrorTest.phpt
  15. +5 −3 tests/Nella/Event/Args/ApplicationRequestTest.phpt
  16. +5 −3 tests/Nella/Event/Args/ApplicationResponseTest.phpt
  17. +5 −3 tests/Nella/Event/Args/ApplicationShutdownTest.phpt
  18. +5 −3 tests/Nella/Event/Args/ApplicationTest.phpt
  19. +5 −3 tests/Nella/Event/Args/ContainerTest.phpt
  20. +5 −3 tests/Nella/Event/Args/VoidTest.phpt
  21. +5 −3 tests/Nella/Event/Config/ExtensionTest.phpt
  22. +5 −3 tests/Nella/Event/EventDispatcherTest.phpt
  23. +5 −3 tests/Nella/Forms/ContainerTest.phpt
  24. +5 −3 tests/Nella/Forms/Controls/DateTest.phpt
  25. +5 −3 tests/Nella/Forms/Controls/DateTimeTest.phpt
  26. +5 −3 tests/Nella/Forms/Controls/TimeTest.phpt
  27. +5 −3 tests/Nella/Forms/FormTest.phpt
  28. +5 −3 tests/Nella/Forms/MultiplerContainerTest.phpt
  29. +5 −3 tests/Nella/Forms/MultiplerTest.phpt
  30. +6 −4 tests/Nella/Latte/Macros/UiMacrosTest.phpt
  31. +5 −3 tests/Nella/Localization/DictionaryTest.phpt
  32. +5 −3 tests/Nella/Localization/DummyTranslatorTest.phpt
  33. +5 −3 tests/Nella/Localization/HelperTest.phpt
  34. +5 −3 tests/Nella/Localization/Storages/GettextBinaryTest.phpt
  35. +5 −3 tests/Nella/Localization/TranslatorTest.phpt
  36. +5 −3 tests/Nella/Media/Callbacks/FilePresenterCallbackTest.phpt
  37. +5 −3 tests/Nella/Media/Callbacks/ImagePresenterCallbackTest.phpt
  38. +5 −3 tests/Nella/Media/Config/ExtensionTest.phpt
  39. +5 −3 tests/Nella/Media/Doctrine/FileEntityTest.phpt
  40. +5 −3 tests/Nella/Media/Doctrine/ImageEntityTest.phpt
  41. +5 −3 tests/Nella/Media/Doctrine/ImageFormatEntityTest.phpt
  42. +5 −3 tests/Nella/Media/HelperTest.phpt
  43. +5 −3 tests/Nella/Media/ImageCacheStorages/FileTest.phpt
  44. +6 −4 tests/Nella/Media/Latte/MediaMacrosTest.phpt
  45. +5 −3 tests/Nella/Media/Model/FileFacadeTest.phpt
  46. +5 −3 tests/Nella/Media/Model/FileTest.phpt
  47. +5 −3 tests/Nella/Media/Model/ImageFacadeTest.phpt
  48. +5 −3 tests/Nella/Media/Model/ImageFormatFacadeTest.phpt
  49. +5 −3 tests/Nella/Media/Model/ImageFormatTest.phpt
  50. +5 −3 tests/Nella/Media/Model/ImageTest.phpt
  51. +5 −3 tests/Nella/Media/Storages/FileTest.phpt
  52. +5 −3 tests/Nella/Model/Config/ExtensionTest.phpt
  53. +9 −4 tests/Nella/Model/HelperTest.phpt
  54. +6 −4 tests/Nella/Model/QueryObjectTest.phpt
  55. +6 −4 tests/Nella/Security/Config/ExtensionTest.phpt
  56. +5 −3 tests/Nella/Security/Model/CredentialsEntityTest.phpt
  57. +5 −3 tests/Nella/Security/Model/IdentityEntityTest.phpt
  58. +5 −3 tests/Nella/SplClassLoaderTest.phpt
  59. +6 −4 tests/Nella/Templating/TemplateFilesFormatterTest.phpt
  60. +10 −3 tests/bootstrap.php
  61. +2 −2 tests/convert-coverage.sh
View
2  build.xml
@@ -135,7 +135,7 @@
</exec>
<exec executable="sh" dir="${basedir}/tests">
<arg path="${basedir}/tests/convert-coverage.sh" />
- <arg value="-d" />
+ <arg value="-o" />
<arg path="${basedir}/build/coverage/index.html" />
</exec>
</target>
View
8 composer.json
@@ -37,11 +37,5 @@
"nella/forms": "self.version",
"nella/media": "self.version",
"nella/localization": "self.version"
- },
- "repositories": [
- {
- "type": "vcs",
- "url": "https://github.com/Vrtak-CZ/nette-tester"
- }
- ]
+ }
}
View
10 tests/Nella/Application/PresenterFactoryTest.phpt
@@ -8,16 +8,16 @@
*
* For the full copyright and license information, please view the file LICENSE.txt that was distributed with this source code.
*
- * @testcase Nella\Tests\Application\PresenterFactoryTest
+ * @testcase
*/
namespace Nella\Tests\Application;
-use Assert;
+use Tester\Assert;
require_once __DIR__ . '/../../bootstrap.php';
-class PresenterFactoryTest extends \TestCase
+class PresenterFactoryTest extends \Tester\TestCase
{
/** @var \Nella\Application\PresenterFactory */
private $loader;
@@ -188,4 +188,6 @@ class MyPresenter extends \Nette\Application\UI\Presenter { }
namespace Nella\Tests\Application\PresenterFactoryTest\Foo;
-class MyPresenter extends \Nette\Application\UI\Presenter { }
+class MyPresenter extends \Nette\Application\UI\Presenter { }
+
+id(new \Nella\Tests\Application\PresenterFactoryTest)->run(isset($_SERVER['argv'][1]) ? $_SERVER['argv'][1] : NULL);
View
10 tests/Nella/Application/UI/ControlTest.phpt
@@ -8,19 +8,19 @@
*
* For the full copyright and license information, please view the file LICENSE.txt that was distributed with this source code.
*
- * @testcase Nella\Tests\Application\UI\ControlTest
+ * @testcase
*/
namespace Nella\Tests\Application\UI;
-use Assert,
+use Tester\Assert,
Nella\Mocks\Application\UI\Presenter;
require_once __DIR__ . '/../../../bootstrap.php';
require_once MOCKS_DIR . '/Application/UI/Presenter.php';
require_once MOCKS_DIR . '/Application/UI/Control.php';
-class ControlTest extends \TestCase
+class ControlTest extends \Tester\TestCase
{
/** @var \Nette\DI\Container */
private $context;
@@ -149,4 +149,6 @@ class ControlTest extends \TestCase
}
}
-class ControlMock extends \Nella\Mocks\Application\UI\Control {}
+class ControlMock extends \Nella\Mocks\Application\UI\Control {}
+
+id(new ControlTest)->run(isset($_SERVER['argv'][1]) ? $_SERVER['argv'][1] : NULL);
View
10 tests/Nella/Application/UI/PresenterTest.phpt
@@ -8,18 +8,18 @@
*
* For the full copyright and license information, please view the file LICENSE.txt that was distributed with this source code.
*
- * @testcase Nella\Tests\Application\UI\PresenterTest
+ * @testcase
*/
namespace Nella\Tests\Application\UI;
-use Assert,
+use Tester\Assert,
Nella\Mocks\Application\UI\Presenter;
require_once __DIR__ . '/../../../bootstrap.php';
require_once MOCKS_DIR . '/Application/UI/Presenter.php';
-class PresenterTest extends \TestCase
+class PresenterTest extends \Tester\TestCase
{
/** @var \Nette\DI\Container */
private $context;
@@ -173,4 +173,6 @@ class PresenterTest extends \TestCase
Assert::equal($eq, $this->presenter->formatTemplateFiles(), "->formatTemplateFiles() $presenter:$view");
}
-}
+}
+
+id(new PresenterTest)->run(isset($_SERVER['argv'][1]) ? $_SERVER['argv'][1] : NULL);
View
10 tests/Nella/Config/ConfiguratorTest.phpt
@@ -8,16 +8,16 @@
*
* For the full copyright and license information, please view the file LICENSE.txt that was distributed with this source code.
*
- * @testcase Nella\Tests\Config\ConfiguratorTest
+ * @testcase
*/
namespace Nella\Tests\Config;
-use Assert;
+use Tester\Assert;
require_once __DIR__ . '/../../bootstrap.php';
-class ConfiguratorTest extends \TestCase
+class ConfiguratorTest extends \Tester\TestCase
{
/** @var \Nella\Config\Configurator */
private $configurator;
@@ -78,4 +78,6 @@ class ConfiguratorMock extends \Nella\Config\Configurator
{
return $this->createCompiler();
}
-}
+}
+
+id(new ConfiguratorTest)->run(isset($_SERVER['argv'][1]) ? $_SERVER['argv'][1] : NULL);
View
8 tests/Nella/Config/Extensions/NellaExtensionTest.phpt
@@ -8,19 +8,19 @@
*
* For the full copyright and license information, please view the file LICENSE.txt that was distributed with this source code.
*
- * @testcase Nella\Tests\Config\Extensions\NellaExtensionTest
+ * @testcase
*/
namespace Nella\Tests\Config\Extensions;
-use Assert,
+use Tester\Assert,
Nella\Mocks\Config\Configurator,
Nella\Config\Extensions\NellaExtension;
require_once __DIR__ . '/../../../bootstrap.php';
require_once MOCKS_DIR . '/Config/Configurator.php';
-class NellaExtensionTest extends \TestCase
+class NellaExtensionTest extends \Tester\TestCase
{
public function testRegister()
{
@@ -33,3 +33,5 @@ class NellaExtensionTest extends \TestCase
Assert::true($extension instanceof NellaExtension);
}
}
+
+id(new NellaExtensionTest)->run(isset($_SERVER['argv'][1]) ? $_SERVER['argv'][1] : NULL);
View
8 tests/Nella/Console/Config/ExtensionTest.phpt
@@ -8,12 +8,12 @@
*
* For the full copyright and license information, please view the file LICENSE.txt that was distributed with this source code.
*
- * @testcase Nella\Tests\Console\Config\ExtensionTest
+ * @testcase
*/
namespace Nella\Tests\Console\Config;
-use Assert,
+use Tester\Assert,
Nella\Mocks\Config\Configurator,
Nella\Mocks\Config\Compiler,
Nella\Console\Config\Extension,
@@ -25,7 +25,7 @@ require_once __DIR__ . '/../../../bootstrap.php';
require_once MOCKS_DIR . '/Config/Configurator.php';
require_once MOCKS_DIR . '/Config/Compiler.php';
-class ExtensionTest extends \TestCase
+class ExtensionTest extends \Tester\TestCase
{
public function testRegister()
{
@@ -111,3 +111,5 @@ class ExtensionTest extends \TestCase
Assert::same($cmd, $application->get('foo'), 'foo command same as test service');
}
}
+
+id(new ExtensionTest)->run(isset($_SERVER['argv'][1]) ? $_SERVER['argv'][1] : NULL);
View
7 tests/Nella/Console/LazyRouteTest.phpt
@@ -8,18 +8,18 @@
*
* For the full copyright and license information, please view the file LICENSE.txt that was distributed with this source code.
*
- * @testcase Nella\Tests\Console\LazyRouterTest
+ * @testcase
*/
namespace Nella\Tests\Console;
-use Assert,
+use Tester\Assert,
Nette\DI\Container,
Nella\Console\LazyRouter;
require_once __DIR__ . '/../../bootstrap.php';
-class LazyRouterTest extends \TestCase
+class LazyRouterTest extends \Tester\TestCase
{
public function testMissingServiceByName()
{
@@ -56,3 +56,4 @@ class LazyRouterTest extends \TestCase
}
}
+id(new LazyRouterTest)->run(isset($_SERVER['argv'][1]) ? $_SERVER['argv'][1] : NULL);
View
8 tests/Nella/Doctrine/CacheTest.phpt
@@ -8,17 +8,17 @@
*
* For the full copyright and license information, please view the file LICENSE.txt that was distributed with this source code.
*
- * @testcase Nella\Tests\Doctrine\CacheTest
+ * @testcase
*/
namespace Nella\Tests\Doctrine;
-use Assert,
+use Tester\Assert,
Nella\Doctrine\Cache;
require_once __DIR__ . '/../../bootstrap.php';
-class CacheTest extends \TestCase
+class CacheTest extends \Tester\TestCase
{
/** @var \Nella\Doctrine\Cache */
private $cache;
@@ -41,3 +41,5 @@ class CacheTest extends \TestCase
Assert::false($this->cache->contains('foo'), "->contains('foo') - removed");
}
}
+
+id(new CacheTest)->run(isset($_SERVER['argv'][1]) ? $_SERVER['argv'][1] : NULL);
View
8 tests/Nella/Doctrine/Config/ExtensionTest.phpt
@@ -8,19 +8,19 @@
*
* For the full copyright and license information, please view the file LICENSE.txt that was distributed with this source code.
*
- * @testcase Nella\Tests\Doctrine\Config\ExtensionTest
+ * @testcase
*/
namespace Nella\Tests\Doctrine\Config;
-use Assert,
+use Tester\Assert,
Nella\Mocks\Config\Configurator,
Nella\Doctrine\Config\Extension;
require_once __DIR__ . '/../../../bootstrap.php';
require_once MOCKS_DIR . '/Config/Configurator.php';
-class ExtensionTest extends \TestCase
+class ExtensionTest extends \Tester\TestCase
{
public function testRegister()
{
@@ -79,3 +79,5 @@ class ExtensionTest extends \TestCase
Assert::true($reader instanceof \Doctrine\Common\Annotations\CachedReader, 'instance');
}
}
+
+id(new ExtensionTest)->run(isset($_SERVER['argv'][1]) ? $_SERVER['argv'][1] : NULL);
View
8 tests/Nella/Doctrine/Config/MigrationsExtensionTest.phpt
@@ -8,19 +8,19 @@
*
* For the full copyright and license information, please view the file LICENSE.txt that was distributed with this source code.
*
- * @testcase Nella\Tests\Doctrine\Config\MigrationsExtensionTest
+ * @testcase
*/
namespace Nella\Tests\Doctrine\Config;
-use Assert,
+use Tester\Assert,
Nella\Mocks\Config\Configurator,
Nella\Doctrine\Config\MigrationsExtension;
require_once __DIR__ . '/../../../bootstrap.php';
require_once MOCKS_DIR . '/Config/Configurator.php';
-class MigrationsExtensionTest extends \TestCase
+class MigrationsExtensionTest extends \Tester\TestCase
{
public function testRegister()
{
@@ -33,3 +33,5 @@ class MigrationsExtensionTest extends \TestCase
Assert::true($extension instanceof MigrationsExtension);
}
}
+
+id(new MigrationsExtensionTest)->run(isset($_SERVER['argv'][1]) ? $_SERVER['argv'][1] : NULL);
View
8 tests/Nella/Doctrine/EntityTest.phpt
@@ -8,16 +8,16 @@
*
* For the full copyright and license information, please view the file LICENSE.txt that was distributed with this source code.
*
- * @testcase Nella\Tests\Doctrine\EntityTest
+ * @testcase
*/
namespace Nella\Tests\Doctrine;
-use Assert;
+use Tester\Assert;
require_once __DIR__ . '/../../bootstrap.php';
-class EntityTest extends \TestCase
+class EntityTest extends \Tester\TestCase
{
/** @var Entity\EntityMock */
private $entity;
@@ -61,3 +61,5 @@ class EntityMock extends \Nella\Doctrine\Entity
$ref->setAccessible(FALSE);
}
}
+
+id(new \Nella\Tests\Doctrine\EntityTest)->run(isset($_SERVER['argv'][1]) ? $_SERVER['argv'][1] : NULL);
View
8 tests/Nella/Event/Args/ApplicationErrorTest.phpt
@@ -8,18 +8,18 @@
*
* For the full copyright and license information, please view the file LICENSE.txt that was distributed with this source code.
*
- * @testcase Nella\Tests\Event\Args\ApplicationErrorTest
+ * @testcase
*/
namespace Nella\Tests\Event\Args;
-use Assert,
+use Tester\Assert,
Nette\Application\Application;
require_once __DIR__ . '/../../../bootstrap.php';
require_once MOCKS_DIR . '/Application/Application.php';
-class ApplicationErrorTest extends \TestCase
+class ApplicationErrorTest extends \Tester\TestCase
{
/** @var \Nella\Event\Args\ApplicationError */
private $args;
@@ -49,3 +49,5 @@ class ApplicationErrorTest extends \TestCase
Assert::true($this->args->exception instanceof \Exception, "->exception");
}
}
+
+id(new ApplicationErrorTest)->run(isset($_SERVER['argv'][1]) ? $_SERVER['argv'][1] : NULL);
View
8 tests/Nella/Event/Args/ApplicationRequestTest.phpt
@@ -8,19 +8,19 @@
*
* For the full copyright and license information, please view the file LICENSE.txt that was distributed with this source code.
*
- * @testcase Nella\Tests\Event\Args\ApplicationRequestTest
+ * @testcase
*/
namespace Nella\Tests\Event\Args;
-use Assert,
+use Tester\Assert,
Nette\Application\Application,
Nette\Application\Request;
require_once __DIR__ . '/../../../bootstrap.php';
require_once MOCKS_DIR . '/Application/Application.php';
-class ApplicationRequestTest extends \TestCase
+class ApplicationRequestTest extends \Tester\TestCase
{
/** @var \Nella\Event\Args\ApplicationRequest */
private $args;
@@ -52,3 +52,5 @@ class ApplicationRequestTest extends \TestCase
Assert::true($this->args->request instanceof Request, "->request");
}
}
+
+id(new ApplicationRequestTest)->run(isset($_SERVER['argv'][1]) ? $_SERVER['argv'][1] : NULL);
View
8 tests/Nella/Event/Args/ApplicationResponseTest.phpt
@@ -8,19 +8,19 @@
*
* For the full copyright and license information, please view the file LICENSE.txt that was distributed with this source code.
*
- * @testcase Nella\Tests\Event\Args\ApplicationResponseTest
+ * @testcase
*/
namespace Nella\Tests\Event\Args;
-use Assert,
+use Tester\Assert,
Nette\Application\Application,
Nette\Application\IResponse;
require_once __DIR__ . '/../../../bootstrap.php';
require_once MOCKS_DIR . '/Application/Application.php';
-class ApplicationResponseTest extends \TestCase
+class ApplicationResponseTest extends \Tester\TestCase
{
/** @var \Nella\Event\Args\ApplicationResponse */
private $args;
@@ -52,3 +52,5 @@ class ApplicationResponseTest extends \TestCase
Assert::true($this->args->response instanceof IResponse, "->response");
}
}
+
+id(new ApplicationResponseTest)->run(isset($_SERVER['argv'][1]) ? $_SERVER['argv'][1] : NULL);
View
8 tests/Nella/Event/Args/ApplicationShutdownTest.phpt
@@ -8,18 +8,18 @@
*
* For the full copyright and license information, please view the file LICENSE.txt that was distributed with this source code.
*
- * @testcase Nella\Tests\Event\Args\ApplicationShutdownTest
+ * @testcase
*/
namespace Nella\Tests\Event\Args;
-use Assert,
+use Tester\Assert,
Nette\Application\Application;
require_once __DIR__ . '/../../../bootstrap.php';
require_once MOCKS_DIR . '/Application/Application.php';
-class ApplicationShutdownTest extends \TestCase
+class ApplicationShutdownTest extends \Tester\TestCase
{
/** @var \Nella\Event\Args\ApplicationShutdown */
private $args;
@@ -49,3 +49,5 @@ class ApplicationShutdownTest extends \TestCase
Assert::true($this->args->exception instanceof \Exception, "->exception");
}
}
+
+id(new ApplicationShutdownTest)->run(isset($_SERVER['argv'][1]) ? $_SERVER['argv'][1] : NULL);
View
8 tests/Nella/Event/Args/ApplicationTest.phpt
@@ -8,18 +8,18 @@
*
* For the full copyright and license information, please view the file LICENSE.txt that was distributed with this source code.
*
- * @testcase Nella\Tests\Event\Args\ApplicationTest
+ * @testcase
*/
namespace Nella\Tests\Event\Args;
-use Assert,
+use Tester\Assert,
Nette\Application\Application;
require_once __DIR__ . '/../../../bootstrap.php';
require_once MOCKS_DIR . '/Application/Application.php';
-class ApplicationTest extends \TestCase
+class ApplicationTest extends \Tester\TestCase
{
/** @var \Nella\Event\Args\Application */
private $args;
@@ -43,3 +43,5 @@ class ApplicationTest extends \TestCase
Assert::true($this->args->application instanceof Application, "->application");
}
}
+
+id(new ApplicationTest)->run(isset($_SERVER['argv'][1]) ? $_SERVER['argv'][1] : NULL);
View
8 tests/Nella/Event/Args/ContainerTest.phpt
@@ -8,17 +8,17 @@
*
* For the full copyright and license information, please view the file LICENSE.txt that was distributed with this source code.
*
- * @testcase Nella\Tests\Event\Args\ContainerTest
+ * @testcase
*/
namespace Nella\Tests\Event\Args;
-use Assert,
+use Tester\Assert,
Nette\DI\Container;
require_once __DIR__ . '/../../../bootstrap.php';
-class ContainerTest extends \TestCase
+class ContainerTest extends \Tester\TestCase
{
/** @var \Nella\Event\Args\Container */
private $args;
@@ -40,3 +40,5 @@ class ContainerTest extends \TestCase
Assert::true($this->args->container instanceof Container, "->application");
}
}
+
+id(new ContainerTest)->run(isset($_SERVER['argv'][1]) ? $_SERVER['argv'][1] : NULL);
View
8 tests/Nella/Event/Args/VoidTest.phpt
@@ -8,16 +8,16 @@
*
* For the full copyright and license information, please view the file LICENSE.txt that was distributed with this source code.
*
- * @testcase Nella\Tests\Event\Args\VoidTest
+ * @testcase
*/
namespace Nella\Tests\Event\Args;
-use Assert;
+use Tester\Assert;
require_once __DIR__ . '/../../../bootstrap.php';
-class VoidTest extends \TestCase
+class VoidTest extends \Tester\TestCase
{
/** @var \Nella\Event\Args\Void */
private $args;
@@ -34,3 +34,5 @@ class VoidTest extends \TestCase
Assert::true($this->args instanceof \Nella\Event\EventArgs);
}
}
+
+id(new VoidTest)->run(isset($_SERVER['argv'][1]) ? $_SERVER['argv'][1] : NULL);
View
8 tests/Nella/Event/Config/ExtensionTest.phpt
@@ -8,19 +8,19 @@
*
* For the full copyright and license information, please view the file LICENSE.txt that was distributed with this source code.
*
- * @testcase Nella\Tests\Event\Config\ExtensionTest
+ * @testcase
*/
namespace Nella\Tests\Event\Config;
-use Assert,
+use Tester\Assert,
Nella\Mocks\Config\Configurator,
Nella\Event\Config\Extension;
require_once __DIR__ . '/../../../bootstrap.php';
require_once MOCKS_DIR . '/Config/Configurator.php';
-class ExtensionTest extends \TestCase
+class ExtensionTest extends \Tester\TestCase
{
public function testRegister()
{
@@ -33,3 +33,5 @@ class ExtensionTest extends \TestCase
Assert::true($extension instanceof Extension);
}
}
+
+id(new ExtensionTest)->run(isset($_SERVER['argv'][1]) ? $_SERVER['argv'][1] : NULL);
View
8 tests/Nella/Event/EventDispatcherTest.phpt
@@ -8,17 +8,17 @@
*
* For the full copyright and license information, please view the file LICENSE.txt that was distributed with this source code.
*
- * @testcase Nella\Tests\Event\EventDispatcherTest
+ * @testcase
*/
namespace Nella\Tests\Event;
-use Assert;
+use Tester\Assert;
require_once __DIR__ . '/../../bootstrap.php';
require_once MOCKS_DIR . '/Config/Configurator.php';
-class EventDispatcherTest extends \TestCase
+class EventDispatcherTest extends \Tester\TestCase
{
/** @var \Nella\Event\EventDispatcher */
private $eventManager;
@@ -151,3 +151,5 @@ class EventSubscriber extends \Nette\Object implements \Nella\Event\IEventSubscr
$args->container->addService('bar', function() { return; });
}
}
+
+id(new EventDispatcherTest)->run(isset($_SERVER['argv'][1]) ? $_SERVER['argv'][1] : NULL);
View
8 tests/Nella/Forms/ContainerTest.phpt
@@ -8,17 +8,17 @@
*
* For the full copyright and license information, please view the file LICENSE.txt that was distributed with this source code.
*
- * @testcase Nella\Tests\Forms\ContainerTest
+ * @testcase
*/
namespace Nella\Tests\Forms;
-use Assert,
+use Tester\Assert,
Nella\Forms\Form;
require_once __DIR__ . '/../../bootstrap.php';
-class ContainerTest extends \TestCase
+class ContainerTest extends \Tester\TestCase
{
/** @var \Nella\Forms\Container */
private $container;
@@ -168,3 +168,5 @@ class ContainerTest extends \TestCase
Assert::true($item instanceof \Nella\Forms\Controls\TagsInput, 'is Nella\Forms\Controls\TagsInput');
}
}
+
+id(new ContainerTest)->run(isset($_SERVER['argv'][1]) ? $_SERVER['argv'][1] : NULL);
View
8 tests/Nella/Forms/Controls/DateTest.phpt
@@ -8,16 +8,16 @@
*
* For the full copyright and license information, please view the file LICENSE.txt that was distributed with this source code.
*
- * @testcase Nella\Tests\Forms\Controls\DateTest
+ * @testcase
*/
namespace Nella\Tests\Forms\Controls;
-use Assert;
+use Tester\Assert;
require_once __DIR__ . '/../../../bootstrap.php';
-class DateTest extends \TestCase
+class DateTest extends \Tester\TestCase
{
/** @var \Nella\Forms\Controls\Date */
private $item;
@@ -54,3 +54,5 @@ class DateTest extends \TestCase
Assert::false($this->item->isFilled(), "validate invalid value");
}
}
+
+id(new DateTest)->run(isset($_SERVER['argv'][1]) ? $_SERVER['argv'][1] : NULL);
View
8 tests/Nella/Forms/Controls/DateTimeTest.phpt
@@ -8,16 +8,16 @@
*
* For the full copyright and license information, please view the file LICENSE.txt that was distributed with this source code.
*
- * @testcase Nella\Tests\Forms\Controls\DateTimeTest
+ * @testcase
*/
namespace Nella\Tests\Forms\Controls;
-use Assert;
+use Tester\Assert;
require_once __DIR__ . '/../../../bootstrap.php';
-class DateTimeTest extends \TestCase
+class DateTimeTest extends \Tester\TestCase
{
/** @var \Nella\Forms\Controls\DateTime */
private $item;
@@ -54,3 +54,5 @@ class DateTimeTest extends \TestCase
Assert::false($this->item->isFilled(), "validate invalid value");
}
}
+
+id(new DateTimeTest)->run(isset($_SERVER['argv'][1]) ? $_SERVER['argv'][1] : NULL);
View
8 tests/Nella/Forms/Controls/TimeTest.phpt
@@ -8,16 +8,16 @@
*
* For the full copyright and license information, please view the file LICENSE.txt that was distributed with this source code.
*
- * @testcase Nella\Tests\Forms\Controls\TimeTest
+ * @testcase
*/
namespace Nella\Tests\Forms\Controls;
-use Assert;
+use Tester\Assert;
require_once __DIR__ . '/../../../bootstrap.php';
-class TimeTest extends \TestCase
+class TimeTest extends \Tester\TestCase
{
/** @var \Nella\Forms\Controls\Time */
private $item;
@@ -54,3 +54,5 @@ class TimeTest extends \TestCase
Assert::false($this->item->isFilled(), "validate invalid value");
}
}
+
+id(new TimeTest)->run(isset($_SERVER['argv'][1]) ? $_SERVER['argv'][1] : NULL);
View
8 tests/Nella/Forms/FormTest.phpt
@@ -8,17 +8,17 @@
*
* For the full copyright and license information, please view the file LICENSE.txt that was distributed with this source code.
*
- * @testcase Nella\Tests\Forms\FormTest
+ * @testcase
*/
namespace Nella\Tests\Forms;
-use Assert,
+use Tester\Assert,
Nella\Forms\Form;
require_once __DIR__ . '/../../bootstrap.php';
-class FormTest extends \TestCase
+class FormTest extends \Tester\TestCase
{
/** @var \Nella\Forms\Form */
private $form;
@@ -166,3 +166,5 @@ class FormTest extends \TestCase
Assert::true($item instanceof \Nella\Forms\Controls\TagsInput, 'is Nella\Forms\Controls\TagsInput');
}
}
+
+id(new FormTest)->run(isset($_SERVER['argv'][1]) ? $_SERVER['argv'][1] : NULL);
View
8 tests/Nella/Forms/MultiplerContainerTest.phpt
@@ -8,17 +8,17 @@
*
* For the full copyright and license information, please view the file LICENSE.txt that was distributed with this source code.
*
- * @testcase Nella\Tests\Forms\MultiplerContainerTest
+ * @testcase
*/
namespace Nella\Tests\Forms;
-use Assert,
+use Tester\Assert,
Nella\Forms\MultiplerContainer;
require_once __DIR__ . '/../../bootstrap.php';
-class MultiplerContainerTest extends \TestCase
+class MultiplerContainerTest extends \Tester\TestCase
{
/** @var \Nella\Forms\MultiplerContainer */
private $container;
@@ -46,3 +46,5 @@ class MultiplerContainerTest extends \TestCase
);
}
}
+
+id(new MultiplerContainerTest)->run(isset($_SERVER['argv'][1]) ? $_SERVER['argv'][1] : NULL);
View
8 tests/Nella/Forms/MultiplerTest.phpt
@@ -8,19 +8,19 @@
*
* For the full copyright and license information, please view the file LICENSE.txt that was distributed with this source code.
*
- * @testcase Nella\Tests\Forms\MultiplerTest
+ * @testcase
*/
namespace Nella\Tests\Forms;
-use Assert,
+use Tester\Assert,
Nella\Forms\Form,
Nella\Forms\Multipler;
require_once __DIR__ . '/../../bootstrap.php';
require_once MOCKS_DIR . '/Application/UI/ControlPresenter.php';
-class MultiplerTest extends \TestCase
+class MultiplerTest extends \Tester\TestCase
{
/** @var \Nella\Forms\Multipler */
protected $multipler;
@@ -213,3 +213,5 @@ class MultiplerTest extends \TestCase
Assert::equal(0, count($containers), "now is 0 containers");
}
}
+
+id(new MultiplerTest)->run(isset($_SERVER['argv'][1]) ? $_SERVER['argv'][1] : NULL);
View
10 tests/Nella/Latte/Macros/UiMacrosTest.phpt
@@ -8,18 +8,18 @@
*
* For the full copyright and license information, please view the file LICENSE.txt that was distributed with this source code.
*
- * @testcase Nella\Tests\Latte\Macros\UIMacrosTest
+ * @testcase
*/
namespace Nella\Tests\Latte\Macros;
-use Assert,
+use Tester\Assert,
Nette\Latte\Compiler,
Nette\Latte\Parser;
require_once __DIR__ . '/../../../bootstrap.php';
-class UIMacrosTest extends \TestCase
+class UIMacrosTest extends \Tester\TestCase
{
/** @var \Nette\Latte\Compiler */
private $compiler;
@@ -57,4 +57,6 @@ class UIMacrosTest extends \TestCase
$actual = $this->compiler->compile($tokens);
Assert::equal($expected, $actual, $input);
}
-}
+}
+
+id(new UIMacrosTest)->run(isset($_SERVER['argv'][1]) ? $_SERVER['argv'][1] : NULL);
View
8 tests/Nella/Localization/DictionaryTest.phpt
@@ -8,16 +8,16 @@
*
* For the full copyright and license information, please view the file LICENSE.txt that was distributed with this source code.
*
- * @testcase Nella\Tests\Localization\DictionaryTest
+ * @testcase
*/
namespace Nella\Tests\Localization;
-use Assert;
+use Tester\Assert;
require_once __DIR__ . '/../../bootstrap.php';
-class DictionaryTest extends \TestCase
+class DictionaryTest extends \Tester\TestCase
{
/** @var \Nella\Localization\Dictionary */
private $dictionary;
@@ -88,3 +88,5 @@ class DictionaryTest extends \TestCase
Assert::equal($metadata, $this->dictionary->metadata, '->metadate return metadata');
}
}
+
+id(new DictionaryTest)->run(isset($_SERVER['argv'][1]) ? $_SERVER['argv'][1] : NULL);
View
8 tests/Nella/Localization/DummyTranslatorTest.phpt
@@ -8,16 +8,16 @@
*
* For the full copyright and license information, please view the file LICENSE.txt that was distributed with this source code.
*
- * @testcase Nella\Tests\Localization\DummyTranslatorTest
+ * @testcase
*/
namespace Nella\Tests\Localization;
-use Assert;
+use Tester\Assert;
require_once __DIR__ . '/../../bootstrap.php';
-class DummyTranslatorTest extends \TestCase
+class DummyTranslatorTest extends \Tester\TestCase
{
/** @var \Nella\Localization\DummyTranslator */
private $translator;
@@ -50,3 +50,5 @@ class DummyTranslatorTest extends \TestCase
);
}
}
+
+id(new DummyTranslatorTest)->run(isset($_SERVER['argv'][1]) ? $_SERVER['argv'][1] : NULL);
View
8 tests/Nella/Localization/HelperTest.phpt
@@ -8,16 +8,16 @@
*
* For the full copyright and license information, please view the file LICENSE.txt that was distributed with this source code.
*
- * @testcase Nella\Tests\Localization\HelperTest
+ * @testcase
*/
namespace Nella\Tests\Localization;
-use Assert;
+use Tester\Assert;
require_once __DIR__ . '/../../bootstrap.php';
-class HelperTest extends \TestCase
+class HelperTest extends \Tester\TestCase
{
public function dataForms()
{
@@ -44,3 +44,5 @@ class HelperTest extends \TestCase
Assert::equal($expected, $form, "from $count to $expected");
}
}
+
+id(new HelperTest)->run(isset($_SERVER['argv'][1]) ? $_SERVER['argv'][1] : NULL);
View
8 tests/Nella/Localization/Storages/GettextBinaryTest.phpt
@@ -8,17 +8,17 @@
*
* For the full copyright and license information, please view the file LICENSE.txt that was distributed with this source code.
*
- * @testcase Nella\Tests\Localization\Storages\GettextBinaryTest
+ * @testcase
*/
namespace Nella\Tests\Localization\Storages;
-use Assert,
+use Tester\Assert,
Nella\Localization\Storages\GettextBinary;
require_once __DIR__ . '/../../../bootstrap.php';
-class GettextBinaryTest extends \TestCase
+class GettextBinaryTest extends \Tester\TestCase
{
public function testInstance()
{
@@ -86,3 +86,5 @@ class GettextBinaryTest extends \TestCase
), iterator_to_array($dictionary), 'dictionary');
}
}
+
+id(new GettextBinaryTest)->run(isset($_SERVER['argv'][1]) ? $_SERVER['argv'][1] : NULL);
View
8 tests/Nella/Localization/TranslatorTest.phpt
@@ -8,17 +8,17 @@
*
* For the full copyright and license information, please view the file LICENSE.txt that was distributed with this source code.
*
- * @testcase Nella\Tests\Localization\TranslatorTest
+ * @testcase
*/
namespace Nella\Tests\Localization;
-use Assert;
+use Tester\Assert;
require_once __DIR__ . '/../../bootstrap.php';
require_once MOCKS_DIR . '/Localization/Storages/Mock.php';
-class TranslatorTest extends \TestCase
+class TranslatorTest extends \Tester\TestCase
{
/** @var \Nella\Localization\Translator */
private $translator;
@@ -71,3 +71,5 @@ class TranslatorTest extends \TestCase
);
}
}
+
+id(new TranslatorTest)->run(isset($_SERVER['argv'][1]) ? $_SERVER['argv'][1] : NULL);
View
8 tests/Nella/Media/Callbacks/FilePresenterCallbackTest.phpt
@@ -8,18 +8,18 @@
*
* For the full copyright and license information, please view the file LICENSE.txt that was distributed with this source code.
*
- * @testcase Nella\Tests\Media\Callbacks\FilePresenterCallbackTest
+ * @testcase
*/
namespace Nella\Tests\Media\Callbacks;
-use Assert,
+use Tester\Assert,
Nella\Mocks\Media\File;
require_once __DIR__ . '/../../../bootstrap.php';
require_once MOCKS_DIR . '/Media/File.php';
-class FilePresenterCallbackTest extends \TestCase
+class FilePresenterCallbackTest extends \Tester\TestCase
{
/** @var \Nella\Media\Callbacks\FilePresenterCallback */
private $callback;
@@ -57,3 +57,5 @@ class FilePresenterCallbackTest extends \TestCase
}, 'Nette\Application\BadRequestException');
}
}
+
+id(new FilePresenterCallbackTest)->run(isset($_SERVER['argv'][1]) ? $_SERVER['argv'][1] : NULL);
View
8 tests/Nella/Media/Callbacks/ImagePresenterCallbackTest.phpt
@@ -8,12 +8,12 @@
*
* For the full copyright and license information, please view the file LICENSE.txt that was distributed with this source code.
*
- * @testcase Nella\Tests\Media\Callbacks\ImagePresenterCallbackTest
+ * @testcase
*/
namespace Nella\Tests\Media\Callbacks;
-use Assert,
+use Tester\Assert,
Nella\Mocks\Media\Image,
Nella\Mocks\Media\Format;
@@ -21,7 +21,7 @@ require_once __DIR__ . '/../../../bootstrap.php';
require_once MOCKS_DIR . '/Media/Image.php';
require_once MOCKS_DIR . '/Media/Format.php';
-class ImagePresenterCallbackTest extends \TestCase
+class ImagePresenterCallbackTest extends \Tester\TestCase
{
/** @var \Nella\Media\Callbacks\FilePresenterCallback */
private $callback;
@@ -64,3 +64,5 @@ class ImagePresenterCallbackTest extends \TestCase
}, 'Nette\Application\BadRequestException');
}
}
+
+id(new ImagePresenterCallbackTest)->run(isset($_SERVER['argv'][1]) ? $_SERVER['argv'][1] : NULL);
View
8 tests/Nella/Media/Config/ExtensionTest.phpt
@@ -8,19 +8,19 @@
*
* For the full copyright and license information, please view the file LICENSE.txt that was distributed with this source code.
*
- * @testcase Nella\Tests\Media\Config\ExtensionTest
+ * @testcase
*/
namespace Nella\Tests\Media\Config;
-use Assert,
+use Tester\Assert,
Nella\Mocks\Config\Configurator,
Nella\Media\Config\Extension;
require_once __DIR__ . '/../../../bootstrap.php';
require_once MOCKS_DIR . '/Config/Configurator.php';
-class ExtensionTest extends \TestCase
+class ExtensionTest extends \Tester\TestCase
{
public function testRegister()
{
@@ -33,3 +33,5 @@ class ExtensionTest extends \TestCase
Assert::true($extension instanceof Extension);
}
}
+
+id(new ExtensionTest)->run(isset($_SERVER['argv'][1]) ? $_SERVER['argv'][1] : NULL);
View
8 tests/Nella/Media/Doctrine/FileEntityTest.phpt
@@ -8,16 +8,16 @@
*
* For the full copyright and license information, please view the file LICENSE.txt that was distributed with this source code.
*
- * @testcase Nella\Tests\Media\Doctrine\FileEntityTest
+ * @testcase
*/
namespace Nella\Tests\Media\Doctrine;
-use Assert;
+use Tester\Assert;
require_once __DIR__ . '/../../../bootstrap.php';
-class FileEntityTest extends \TestCase
+class FileEntityTest extends \Tester\TestCase
{
/** @var \Nella\Media\Doctrine\FileEntity */
private $file;
@@ -72,3 +72,5 @@ class FileEntityTest extends \TestCase
);
}
}
+
+id(new FileEntityTest)->run(isset($_SERVER['argv'][1]) ? $_SERVER['argv'][1] : NULL);
View
8 tests/Nella/Media/Doctrine/ImageEntityTest.phpt
@@ -8,16 +8,16 @@
*
* For the full copyright and license information, please view the file LICENSE.txt that was distributed with this source code.
*
- * @testcase Nella\Tests\Media\Doctrine\ImageEntityTest
+ * @testcase
*/
namespace Nella\Tests\Media\Doctrine;
-use Assert;
+use Tester\Assert;
require_once __DIR__ . '/../../../bootstrap.php';
-class ImageEntityTest extends \TestCase
+class ImageEntityTest extends \Tester\TestCase
{
/** @var \Nella\Media\Doctrine\ImageEntity */
private $image;
@@ -73,3 +73,5 @@ class ImageEntityTest extends \TestCase
);
}
}
+
+id(new ImageEntityTest)->run(isset($_SERVER['argv'][1]) ? $_SERVER['argv'][1] : NULL);
View
8 tests/Nella/Media/Doctrine/ImageFormatEntityTest.phpt
@@ -8,17 +8,17 @@
*
* For the full copyright and license information, please view the file LICENSE.txt that was distributed with this source code.
*
- * @testcase Nella\Tests\Media\Doctrine\ImageFormatEntityTest
+ * @testcase
*/
namespace Nella\Tests\Media\Doctrine;
-use Assert,
+use Tester\Assert,
Nella\Media\Doctrine\ImageFormatEntity;
require_once __DIR__ . '/../../../bootstrap.php';
-class ImageFormatEntityTest extends \TestCase
+class ImageFormatEntityTest extends \Tester\TestCase
{
/** @var \Nella\Media\Doctrine\ImageFormatEntity */
private $format;
@@ -83,3 +83,5 @@ class ImageFormatEntityTest extends \TestCase
);
}
}
+
+id(new ImageFormatEntityTest)->run(isset($_SERVER['argv'][1]) ? $_SERVER['argv'][1] : NULL);
View
8 tests/Nella/Media/HelperTest.phpt
@@ -8,17 +8,17 @@
*
* For the full copyright and license information, please view the file LICENSE.txt that was distributed with this source code.
*
- * @testcase Nella\Tests\Media\HelperTest
+ * @testcase
*/
namespace Nella\Tests\Media;
-use Assert,
+use Tester\Assert,
Nella\Media\Helper;
require_once __DIR__ . '/../../bootstrap.php';
-class HelperTest extends \TestCase
+class HelperTest extends \Tester\TestCase
{
public function dataExtToMime()
{
@@ -60,3 +60,5 @@ class HelperTest extends \TestCase
Assert::equal($ext, Helper::mimeTypeToExt($mime), "::mimeTypeToExt('$mime')");
}
}
+
+id(new HelperTest)->run(isset($_SERVER['argv'][1]) ? $_SERVER['argv'][1] : NULL);
View
8 tests/Nella/Media/ImageCacheStorages/FileTest.phpt
@@ -8,12 +8,12 @@
*
* For the full copyright and license information, please view the file LICENSE.txt that was distributed with this source code.
*
- * @testcase Nella\Tests\Media\ImageCacheStorages\FileTest
+ * @testcase
*/
namespace Nella\Tests\Media\ImageCacheStorages;
-use Assert,
+use Tester\Assert,
Nette\Caching\Cache,
Nella\Media\ImageCacheStorages\File,
Nella\Mocks\Media\Image,
@@ -23,7 +23,7 @@ require_once __DIR__ . '/../../../bootstrap.php';
require_once MOCKS_DIR . '/Media/Image.php';
require_once MOCKS_DIR . '/Media/Format.php';
-class FileTest extends \TestCase
+class FileTest extends \Tester\TestCase
{
/** @var \Nella\Media\ImageCacheStorages\File */
private $storage;
@@ -167,3 +167,5 @@ class FileTest extends \TestCase
$this->removeImage($src);
}
}
+
+id(new FileTest)->run(isset($_SERVER['argv'][1]) ? $_SERVER['argv'][1] : NULL);
View
10 tests/Nella/Media/Latte/MediaMacrosTest.phpt
@@ -8,18 +8,18 @@
*
* For the full copyright and license information, please view the file LICENSE.txt that was distributed with this source code.
*
- * @testcase Nella\Tests\Media\Latte\MediaMacrosTest
+ * @testcase
*/
namespace Nella\Tests\Media\Latte;
-use Assert,
+use Tester\Assert,
Nette\Latte\Compiler,
Nette\Latte\Parser;
require_once __DIR__ . '/../../../bootstrap.php';
-class MediaMacrosTest extends \TestCase
+class MediaMacrosTest extends \Tester\TestCase
{
/** @var \Nette\Latte\Compiler */
private $compiler;
@@ -165,4 +165,6 @@ class MediaMacrosTest extends \TestCase
$actual = $this->compiler->compile($tokens);
Assert::equal($expected, $actual, $macro);
}
-}
+}
+
+id(new MediaMacrosTest)->run(isset($_SERVER['argv'][1]) ? $_SERVER['argv'][1] : NULL);
View
8 tests/Nella/Media/Model/FileFacadeTest.phpt
@@ -8,16 +8,16 @@
*
* For the full copyright and license information, please view the file LICENSE.txt that was distributed with this source code.
*
- * @testcase Nella\Tests\Media\Model\FileFacadeTest
+ * @testcase
*/
namespace Nella\Tests\Media\Model;
-use Assert;
+use Tester\Assert;
require_once __DIR__ . '/../../../bootstrap.php';
-class FileFacadeTest extends \TestCase
+class FileFacadeTest extends \Tester\TestCase
{
const SLUG = 'logo_png';
/** @var \Nella\Media\Model\FileFacade */
@@ -41,3 +41,5 @@ class FileFacadeTest extends \TestCase
Assert::equal('logo', $file->getFullSlug());
}
}
+
+id(new FileFacadeTest)->run(isset($_SERVER['argv'][1]) ? $_SERVER['argv'][1] : NULL);
View
8 tests/Nella/Media/Model/FileTest.phpt
@@ -8,16 +8,16 @@
*
* For the full copyright and license information, please view the file LICENSE.txt that was distributed with this source code.
*
- * @testcase Nella\Tests\Media\Model\FileTest
+ * @testcase
*/
namespace Nella\Tests\Media\Model;
-use Assert;
+use Tester\Assert;
require_once __DIR__ . '/../../../bootstrap.php';
-class FileTest extends \TestCase
+class FileTest extends \Tester\TestCase
{
const PATH = 'logo.png';
/** @var \Nella\Media\Model\File */
@@ -58,3 +58,5 @@ class FileTest extends \TestCase
Assert::equal('logo', $this->file->fullSlug, '->fullSlug');
}
}
+
+id(new FileTest)->run(isset($_SERVER['argv'][1]) ? $_SERVER['argv'][1] : NULL);
View
8 tests/Nella/Media/Model/ImageFacadeTest.phpt
@@ -8,16 +8,16 @@
*
* For the full copyright and license information, please view the file LICENSE.txt that was distributed with this source code.
*
- * @testcase Nella\Tests\Media\Model\ImageFacadeTest
+ * @testcase
*/
namespace Nella\Tests\Media\Model;
-use Assert;
+use Tester\Assert;
require_once __DIR__ . '/../../../bootstrap.php';
-class ImageFacadeTest extends \TestCase
+class ImageFacadeTest extends \Tester\TestCase
{
const SLUG = 'logo_png';
/** @var \Nella\Media\Model\ImageFacade */
@@ -41,3 +41,5 @@ class ImageFacadeTest extends \TestCase
Assert::equal('logo', $image->getFullSlug());
}
}
+
+id(new ImageFacadeTest)->run(isset($_SERVER['argv'][1]) ? $_SERVER['argv'][1] : NULL);
View
8 tests/Nella/Media/Model/ImageFormatFacadeTest.phpt
@@ -8,16 +8,16 @@
*
* For the full copyright and license information, please view the file LICENSE.txt that was distributed with this source code.
*
- * @testcase Nella\Tests\Media\Model\ImageFormatFacadeTest
+ * @testcase
*/
namespace Nella\Tests\Media\Model;
-use Assert;
+use Tester\Assert;
require_once __DIR__ . '/../../../bootstrap.php';
-class ImageFormatFacadeTest extends \TestCase
+class ImageFormatFacadeTest extends \Tester\TestCase
{
const SLUG = 'default';
/** @var \Nella\Media\Model\ImageFormatFacade */
@@ -51,3 +51,5 @@ class ImageFormatFacadeTest extends \TestCase
}
}
+
+id(new ImageFormatFacadeTest)->run(isset($_SERVER['argv'][1]) ? $_SERVER['argv'][1] : NULL);
View
8 tests/Nella/Media/Model/ImageFormatTest.phpt
@@ -8,18 +8,18 @@
*
* For the full copyright and license information, please view the file LICENSE.txt that was distributed with this source code.
*
- * @testcase Nella\Tests\Media\Model\ImageFormatTest
+ * @testcase
*/
namespace Nella\Tests\Media\Model;
-use Assert,
+use Tester\Assert,
Nella\Media\IImageFormat;
require_once __DIR__ . '/../../../bootstrap.php';
require_once MOCKS_DIR . '/Media/Image.php';
-class ImageFormatTest extends \TestCase
+class ImageFormatTest extends \Tester\TestCase
{
/** @var \Nella\Media\Model\ImageFormat */
private $format;
@@ -98,3 +98,5 @@ class ImageFormatTest extends \TestCase
Assert::equal(IImageFormat::POSITION_CENTER, $this->format->watermarkPosition, '->watermarkPosition');
}
}
+
+id(new ImageFormatTest)->run(isset($_SERVER['argv'][1]) ? $_SERVER['argv'][1] : NULL);
View
8 tests/Nella/Media/Model/ImageTest.phpt
@@ -8,17 +8,17 @@
*
* For the full copyright and license information, please view the file LICENSE.txt that was distributed with this source code.
*
- * @testcase Nella\Tests\Media\Model\ImageTest
+ * @testcase
*/
namespace Nella\Tests\Media\Model;
-use Assert,
+use Tester\Assert,
Nella\Media\Model\Image;
require_once __DIR__ . '/../../../bootstrap.php';
-class ImageTest extends \TestCase
+class ImageTest extends \Tester\TestCase
{
const PATH = 'logo.png';
/** @var \Nella\Media\Model\Image */
@@ -73,3 +73,5 @@ class ImageTest extends \TestCase
}, 'Nette\InvalidArgumentException');
}
}
+
+id(new ImageTest)->run(isset($_SERVER['argv'][1]) ? $_SERVER['argv'][1] : NULL);
View
8 tests/Nella/Media/Storages/FileTest.phpt
@@ -8,18 +8,18 @@
*
* For the full copyright and license information, please view the file LICENSE.txt that was distributed with this source code.
*
- * @testcase Nella\Tests\Media\Storages\FileTest
+ * @testcase
*/
namespace Nella\Tests\Media\Storages;
-use Assert,
+use Tester\Assert,
Nella\Mocks\Media\File as FileMock;
require_once __DIR__ . '/../../../bootstrap.php';
require_once MOCKS_DIR . '/Media/File.php';
-class FileTest extends \TestCase
+class FileTest extends \Tester\TestCase
{
/** @var \Nella\Media\Storages\File */
private $storage;
@@ -108,3 +108,5 @@ class FileTest extends \TestCase
Assert::null($this->storage->load($file));
}
}
+
+id(new FileTest)->run(isset($_SERVER['argv'][1]) ? $_SERVER['argv'][1] : NULL);
View
8 tests/Nella/Model/Config/ExtensionTest.phpt
@@ -8,19 +8,19 @@
*
* For the full copyright and license information, please view the file LICENSE.txt that was distributed with this source code.
*
- * @testcase Nella\Tests\Model\Config\ExtensionTest
+ * @testcase
*/
namespace Nella\Tests\Model\Config;
-use Assert,
+use Tester\Assert,
Nella\Mocks\Config\Configurator,
Nella\Model\Config\Extension;
require_once __DIR__ . '/../../../bootstrap.php';
require_once MOCKS_DIR . '/Config/Configurator.php';
-class ExtensionTest extends \TestCase
+class ExtensionTest extends \Tester\TestCase
{
public function testRegister()
{
@@ -33,3 +33,5 @@ class ExtensionTest extends \TestCase
Assert::true($extension instanceof Extension);
}
}
+
+id(new ExtensionTest)->run(isset($_SERVER['argv'][1]) ? $_SERVER['argv'][1] : NULL);
View
13 tests/Nella/Model/HelperTest.phpt
@@ -8,17 +8,17 @@
*
* For the full copyright and license information, please view the file LICENSE.txt that was distributed with this source code.
*
- * @testcase Nella\Tests\Model\HelperTest
+ * @testcase
*/
namespace Nella\Tests\Model;
-use Assert,
+use Tester\Assert,
Nella\Model\Helper;
require_once __DIR__ . '/../../bootstrap.php';
-class HelperTest extends \TestCase
+class HelperTest extends \Tester\TestCase
{
public function dataConvertException()
{
@@ -46,9 +46,12 @@ class HelperTest extends \TestCase
try {
Helper::convertException($exception);
} catch (\Nella\Model\Exception $e) {
- Assert::exception($class, $message, $e);
Assert::same($exception, $e->getPrevious());
}
+
+ Assert::exception(function() use($exception) {
+ Helper::convertException($exception);
+ }, $class, $message);
}
public function testAdvancedEmptyValueException()
@@ -63,3 +66,5 @@ class HelperTest extends \TestCase
}
}
}
+
+id(new HelperTest)->run(isset($_SERVER['argv'][1]) ? $_SERVER['argv'][1] : NULL);
View
10 tests/Nella/Model/QueryObjectTest.phpt
@@ -8,17 +8,17 @@
*
* For the full copyright and license information, please view the file LICENSE.txt that was distributed with this source code.
*
- * @testcase Nella\Tests\Model\QueryObjectTest
+ * @testcase
*/
namespace Nella\Tests\Model;
-use Assert,
+use Tester\Assert,
Nella\Model\QueryObject;
require_once __DIR__ . '/../../bootstrap.php';
-class QueryObjectTest extends \TestCase
+class QueryObjectTest extends \Tester\TestCase
{
/** @var \Nella\Model\IQueryObject */
private $query;
@@ -43,4 +43,6 @@ class QueryObjectTest extends \TestCase
$query = new QueryObject($paginator);
Assert::same($paginator, $query->getPaginator(), '->getPaginator() same');
}
-}
+}
+
+id(new QueryObjectTest)->run(isset($_SERVER['argv'][1]) ? $_SERVER['argv'][1] : NULL);
View
10 tests/Nella/Security/Config/ExtensionTest.phpt
@@ -8,19 +8,19 @@
*
* For the full copyright and license information, please view the file LICENSE.txt that was distributed with this source code.
*
- * @testcase Nella\Tests\Security\Config\ExtensionTest
+ * @testcase
*/
namespace Nella\Tests\Security\Config;
-use Assert,
+use Tester\Assert,
Nella\Mocks\Config\Configurator,
Nella\Security\Config\Extension;
require_once __DIR__ . '/../../../bootstrap.php';
require_once MOCKS_DIR . '/Config/Configurator.php';
-class ExtensionTest extends \TestCase
+class ExtensionTest extends \Tester\TestCase
{
public function testRegister()
{
@@ -33,4 +33,6 @@ class ExtensionTest extends \TestCase
Assert::true($extension instanceof \Nette\Config\CompilerExtension);
Assert::true($extension instanceof Extension);
}
-}
+}
+
+id(new ExtensionTest)->run(isset($_SERVER['argv'][1]) ? $_SERVER['argv'][1] : NULL);
View
8 tests/Nella/Security/Model/CredentialsEntityTest.phpt
@@ -8,16 +8,16 @@
*
* For the full copyright and license information, please view the file LICENSE.txt that was distributed with this source code.
*
- * @testcase Nella\Tests\Security\Model\CredentialsEntityTest
+ * @testcase
*/
namespace Nella\Tests\Security\Model;
-use Assert;
+use Tester\Assert;
require_once __DIR__ . '/../../../bootstrap.php';
-class CredentialsEntityTest extends \TestCase
+class CredentialsEntityTest extends \Tester\TestCase
{
/** @var \Nella\Security\Model\IdentityEntity */
private $identity;
@@ -88,3 +88,5 @@ class CredentialsEntityTest extends \TestCase
Assert::false($this->credentials->verifyPassword("fail"));
}
}
+
+id(new CredentialsEntityTest)->run(isset($_SERVER['argv'][1]) ? $_SERVER['argv'][1] : NULL);
View
8 tests/Nella/Security/Model/IdentityEntityTest.phpt
@@ -8,16 +8,16 @@
*
* For the full copyright and license information, please view the file LICENSE.txt that was distributed with this source code.
*
- * @testcase Nella\Tests\Security\Model\IdentityEntityTest
+ * @testcase
*/
namespace Nella\Tests\Security\Model;
-use Assert;
+use Tester\Assert;
require_once __DIR__ . '/../../../bootstrap.php';
-class IdentityEntityTest extends \TestCase
+class IdentityEntityTest extends \Tester\TestCase
{
/** @var \Nella\Security\Model\IdentityEntity */
private $identity;
@@ -71,3 +71,5 @@ class IdentityEntityTest extends \TestCase
);
}
}
+
+id(new IdentityEntityTest)->run(isset($_SERVER['argv'][1]) ? $_SERVER['argv'][1] : NULL);
View
8 tests/Nella/SplClassLoaderTest.phpt
@@ -8,16 +8,16 @@
*
* For the full copyright and license information, please view the file LICENSE.txt that was distributed with this source code.
*
- * @testcase Nella\Tests\SplClassLoaderTest
+ * @testcase
*/
namespace Nella\Tests;
-use Assert;
+use Tester\Assert;
require_once __DIR__ . '/../bootstrap.php';
-class SplClassLoaderTest extends \TestCase
+class SplClassLoaderTest extends \Tester\TestCase
{
public function setUp()
{
@@ -37,3 +37,5 @@ class SplClassLoaderTest extends \TestCase
Assert::false(class_exists('NellaTests\SplClassLoader\Bar'));
}
}
+
+id(new SplClassLoaderTest)->run(isset($_SERVER['argv'][1]) ? $_SERVER['argv'][1] : NULL);
View
10 tests/Nella/Templating/TemplateFilesFormatterTest.phpt
@@ -8,16 +8,16 @@
*
* For the full copyright and license information, please view the file LICENSE.txt that was distributed with this source code.
*
- * @testcase Nella\Tests\Templating\TemplateFilesFormatterTest
+ * @testcase
*/
namespace Nella\Tests\Templating;
-use Assert;
+use Tester\Assert;
require_once __DIR__ . '/../../bootstrap.php';
-class TemplateFilesFormatterTest extends \TestCase
+class TemplateFilesFormatterTest extends \Tester\TestCase
{
/** @var \Nella\Templating\TemplateFilesFormatter */
private $formatter;
@@ -276,4 +276,6 @@ class TemplateFilesFormatterTest extends \TestCase
{
Assert::equal($expected, $this->formatter->formatComponentTemplateFiles($class, $view));
}
-}
+}
+
+id(new TemplateFilesFormatterTest)->run(isset($_SERVER['argv'][1]) ? $_SERVER['argv'][1] : NULL);
View
13 tests/bootstrap.php
@@ -20,12 +20,19 @@
// configure environment
date_default_timezone_set('Europe/Prague');
-//TestHelpers::purge(TEMP_DIR);
+
+if (!class_exists('Tester\Assert')) {
+ echo "Install Nette Tester using `composer update --dev`\n";
+ exit(1);
+}
Debugger::$strictMode = TRUE;
Debugger::enable(Debugger::DEVELOPMENT, TEMP_DIR . '/log');
+function id($val) {
+ return $val;
+}
+
if (extension_loaded('xdebug')) {
- xdebug_disable();
- TestHelpers::startCodeCoverage(TESTS_DIR . '/coverage.dat');
+ Tester\CodeCoverage\Collector::start(__DIR__ . '/coverage.dat');
}
View
4 tests/convert-coverage.sh
@@ -4,7 +4,7 @@
dir=$(cd `dirname $0` && pwd)
# Path to test runner script
-runnerScript="$dir/../vendor/nette/tester/Tester/ConvertCoverage.phpc"
+runnerScript="$dir/../vendor/nette/tester/Tester/coverage-report.php"
if [ ! -f "$runnerScript" ]; then
echo "Nette Tester is missing. You can install it using Composer:" >&2
echo "php composer.phar update --dev." >&2
@@ -12,4 +12,4 @@ if [ ! -f "$runnerScript" ]; then
fi
# Runs converter with script's arguments
-php "$runnerScript" -f "coverage.dat" -s "$dir/../Nella" -n "Nella Framework" -e "*.phtml" -e "*.md" -e "*.json" -e "Diagnostics/*" -e "loader.php" "$@"
+php "$runnerScript" -c "coverage.dat" -s "$dir/../Nella" -t "Nella Framework" "$@"
Please sign in to comment.
Something went wrong with that request. Please try again.