public function setUp() { parent::setUp(); // Set the languages config()->set('translatable.locales', ['en', 'tr']); $this->setUpNodeType(); }
public function setup() { parent::setup(); $this->scheduleRepository = $this->getMock('IScheduleRepository'); $this->layout = $this->getMock('IScheduleLayout'); $this->rule = new SchedulePeriodRule($this->scheduleRepository, $this->fakeUser); }
public function setup() { parent::setup(); $this->attributeService = $this->getMock('IAttributeService'); $this->userRepository = $this->getMock('IUserViewRepository'); $this->validator = new UserRequestValidator($this->attributeService, $this->userRepository); }
public function setup() { parent::setup(); $this->server = new FakeRestServer(); $this->controller = $this->getMock('IUserSaveController'); $this->service = new UsersWriteWebService($this->server, $this->controller); }
public function setUp() { parent::setUp(); // We do this due to a bug // otherwise helper is not loaded app()->make('settings'); }
public function setup() { parent::setup(); $this->activationRepo = $this->getMock('IAccountActivationRepository'); $this->userRepo = $this->getMock('IUserRepository'); $this->activation = new AccountActivation($this->activationRepo, $this->userRepo); }
public function setUp() { parent::setUp(); $this->path = FIXTURES . DS . 'tests'; $this->bootstrap = dirname(FIXTURES) . DS . 'bootstrap.php'; $this->phpunitWrapper = PARATEST_ROOT . '/bin/phpunit-wrapper'; }
public function setUp() { parent::setUp(); if (!self::$connectionSet) { LudoDb::setConnectionType('PDO'); } }
public function setup() { parent::setup(); $this->page = new FakeSavedReportsPage(); $this->service = $this->getMock('IReportingService'); $this->presenter = new SavedReportsPresenter($this->page, $this->fakeUser, $this->service); }
public function setup() { parent::setup(); $this->fakeAuth = new FakeAuth(); $this->loginContext = $loginContext = new WebLoginContext(new LoginData(true)); $this->webAuth = new WebAuthentication($this->fakeAuth, $this->fakeServer); }
public function setUp() { parent::setUp(); $this->setUpNodeType(); NodeSource::flushEventListeners(); NodeSource::boot(); }
public function setup() { parent::setup(); $this->attributeRepository = new FakeAttributeRepository(); $this->controller = new AttributeSaveController($this->attributeRepository); $this->session = new FakeWebServiceUserSession(1); }
public function setup() { $this->userRepository = $this->getMock('IUserRepository'); $this->user = new FakeUserSession(); $this->repo = new ScheduleAdminScheduleRepository($this->userRepository, $this->user); parent::setup(); }
public function setUp() { parent::setUp(); $s = new Section(); $s->drop()->yesImSure(); $s->createTable(); }
public function setup() { parent::setup(); $this->page = $this->getMock('IManageResourceGroupsPage'); $this->resourceRepository = $this->getMock('IResourceRepository'); $this->presenter = new ManageResourceGroupsPresenter($this->page, $this->fakeUser, $this->resourceRepository); }
public function setup() { parent::setup(); $this->page = $this->getMock('ICalendarSubscriptionPage'); $this->subscriptionService = $this->getMock('ICalendarSubscriptionService'); $this->validator = new CalendarSubscriptionValidator($this->page, $this->subscriptionService); }
public function setUp() { parent::setUp(); $g = new TestGame(); $g->drop()->yesImSure(); $g->createTable(); }
public function setup() { parent::setup(); $this->authentication = $this->getMock('IWebServiceAuthentication'); $this->server = new FakeRestServer(); $this->service = new AuthenticationWebService($this->server, $this->authentication); }
public function setUp() { parent::setUp(); // Let the current user do anything. global $current_user; $current_user->add_cap('promote_users'); }
public function setup() { parent::setup(); $this->now = Date::Parse('2011-07-20 13:41:22', 'America/Chicago'); Date::_SetNow($this->now); $this->timezone = $this->now->Timezone(); }
public function setup() { parent::setup(); $this->attributeService = $this->getMock('IAttributeService'); $this->server = new FakeRestServer(); $this->service = new AttributesWebService($this->server, $this->attributeService); }
public function teardown() { parent::teardown(); $this->page = null; $this->fakeReg = null; $this->fakeAuth = null; }
public function setup() { parent::setup(); $this->page = new FakeAttributePage(); $this->attributeRepository = $this->getMock('IAttributeRepository'); $this->presenter = new ManageAttributesPresenter($this->page, $this->attributeRepository); }
public function setup() { parent::setup(); $this->page = $this->getMock('IActivationPage'); $this->accountActivation = new FakeActivation(); $this->auth = new FakeWebAuthentication(); $this->presenter = new ActivationPresenter($this->page, $this->accountActivation, $this->auth); }
public function setup() { parent::setup(); $this->userRepo = $this->getMock('IUserRepository'); $this->resourceRepo = $this->getMock('IResourceRepository'); $this->scheduleRepo = $this->getMock('IScheduleRepository'); $this->service = new CalendarSubscriptionService($this->userRepo, $this->resourceRepo, $this->scheduleRepo); }
public function setUp() { parent::setUp(); $this->root = vfsStream::setup('root_dir', null, ['foo.txt' => 'foobar', 'bar.php' => '<?php echo "bar";']); vfsStream::newFile('large.txt')->withContent(LargeFileContent::withMegabytes(100))->at($this->root); app()['path.upload'] = vfsStream::url('root_dir') . '/upload'; $this->uploadService = app()->make('transit.upload'); }
public function setup() { $this->validator = $this->getMock('IResourceRequestValidator'); $this->repository = $this->getMock('IResourceRepository'); $this->session = new FakeWebServiceUserSession(1); $this->controller = new ResourceSaveController($this->repository, $this->validator); parent::setup(); }
public function setup() { parent::setup(); $this->reservationViewRepository = $this->getMock('IReservationViewRepository'); $this->userRepository = $this->getMock('IUserRepository'); $this->reservationAuthorization = $this->getMock('IReservationAuthorization'); $this->service = new ResourceAdminManageReservationsService($this->reservationViewRepository, $this->userRepository, $this->reservationAuthorization, $this->getMock('IReservationHandler'), $this->getMock('IUpdateReservationPersistenceService')); }
protected function tearDown() { $testcoverageFile = sys_get_temp_dir() . DS . 'testcoverage.php'; if (file_exists($testcoverageFile)) { unlink($testcoverageFile); } parent::tearDown(); }
public function setup() { parent::setup(); $this->authorizationService = $this->getMock('IAuthorizationService'); $this->currentUser = new FakeUserSession(false, null, 998); $this->adminUser = new FakeUserSession(true, null, 999); $this->reservationAuthorization = new ReservationAuthorization($this->authorizationService); }