Esempio n. 1
0
	protected function setup()
	{
		parent::setup();
		$this->object = new FreezableObjectMock;
		$this->object->onFreeze[] = function($object) {
			$object->test .= "TRUE";
		};
	}
	public function setup()
	{
		parent::setup();
		$container = new \Nette\DI\Container;
		$container->params = array('productionMode' => FALSE, 'appDir' => __DIR__ . "/..");
		$container->addService('migrationConfiguration', new \Doctrine\DBAL\Migrations\Configuration\Configuration(
			new \Doctrine\DBAL\Connection(array(), new \Doctrine\DBAL\Driver\PDOSqlite\Driver)
		));
		$container = new \Nella\Doctrine\Container($container);
		$this->helper = new \Nella\Doctrine\MigrationConfigurationHelper($container);
	}
	public function setup()
	{
		parent::setup();
		$container = new \Nette\DI\Container;
		$container->params = array('productionMode' => FALSE, 'appDir' => __DIR__ . "/..");
		$container->addService('entityManager', \Doctrine\Tests\Mocks\EntityManagerMock::create(
			new \Doctrine\DBAL\Connection(array(), new \Doctrine\DBAL\Driver\PDOSqlite\Driver)
		));
		$this->dc = new \Nella\Doctrine\Container($container);
		$this->helper = new \Nella\Doctrine\EntityManagerHelper($this->dc);
	}
Esempio n. 4
0
	public function setup()
	{
		parent::setup();
		$this->context->params['namespaces'] = array('App', 'NellaTests\Application\UI', 'Nella');
		$this->context->params['templates'] = array(
			$this->context->params['appDir'],
			__DIR__,
			NELLA_FRAMEWORK_DIR,
		);
		$this->presenter = new Presenter\PresenterMock;
		$this->presenter->setContext($this->context);
	}
Esempio n. 5
0
	public function setup()
	{
		parent::setup();
		$this->helper = new \Nella\DI\ContainerHelper($this->context);
	}
Esempio n. 6
0
	public function setup()
	{
		parent::setup();
		$this->cache = new \Nella\Doctrine\Cache(new \Nette\Caching\Storages\MemoryStorage);
	}
Esempio n. 7
0
	public function setUp()
	{
		parent::setup();
		$this->storage = new \Nella\Localization\Storages\Gettext(__DIR__ . "/GettextTest.mo");
	}
Esempio n. 8
0
	public function setup()
	{
		parent::setup();
		$this->context->params['namespaces'] = array('App', 'Nella');
		$this->loader = new \Nella\Application\PresenterFactory($this->context);
	}
Esempio n. 9
0
	public function setup()
	{
		parent::setup();
		$this->container = new \Nella\Application\UI\ComponentContainer;
	}
Esempio n. 10
0
	public function setup()
	{
		parent::setup();
		$this->arr = new \Nella\FreezableArray;
		$this->arr['foo'] = "bar";
	}
Esempio n. 11
0
	public function setup()
	{
		parent::setup();
		$this->presenter = new BackendPresenter\PresenterMock;
		$this->presenter->setContext($this->context);
	}