/** * @test */ public function setRegistrationDataForMissingCountrySetsEmptyCountry() { $className = $this->createAccessibleProxyClass(); /** @var tx_seminars_registrationmanager $fixture */ $fixture = new $className(); /** @var tx_seminars_Model_Event $event */ $event = tx_oelib_MapperRegistry::get('tx_seminars_Mapper_Event')->getLoadedTestingModel(array()); $registration = new tx_seminars_Model_Registration(); $registration->setEvent($event); $fixture->setRegistrationData($registration, array()); self::assertSame('', $registration->getCountry()); }
/** * Attaches a registration to this event. * * @param tx_seminars_Model_Registration $registration * the registration to attach * * @return void */ public function attachRegistration(tx_seminars_Model_Registration $registration) { $registration->setEvent($this); $this->getRegistrations()->add($registration); }
/** * @test */ public function setEventSetsEvent() { $event = tx_oelib_MapperRegistry::get('tx_seminars_Mapper_Event')->getNewGhost(); $this->fixture->setEvent($event); self::assertSame($event, $this->fixture->getEvent()); }