Esempio n. 1
0
 /**
  * Factory methods
  */
 public function testFactoryMethods()
 {
     $this->factory->setOverwrite(true);
     $this->assertTrue($this->factory->isOverwrite());
     $this->factory->setOutputPath('/tmp');
     $this->assertEquals($this->factory->getOutputPath(), '/tmp');
 }
Esempio n. 2
0
 public function testRequiredInformationInPassNotOverwrittenByFactory()
 {
     $passOrganizationName = 'organization name in pass';
     $passTeamIdentifier = 'team identifier in pass';
     $passPassTypeIdentifier = 'pass type identifier in pass';
     $pass = new Pass('serial number', 'description');
     $pass->setOrganizationName($passOrganizationName);
     $pass->setTeamIdentifier($passTeamIdentifier);
     $pass->setPassTypeIdentifier($passPassTypeIdentifier);
     $this->factory->setOutputPath('/tmp');
     $this->factory->setOverwrite(true);
     $this->factory->setSkipSignature(true);
     $this->factory->package($pass);
     self::assertEquals($passOrganizationName, $pass->getOrganizationName());
     self::assertEquals($passTeamIdentifier, $pass->getTeamIdentifier());
     self::assertEquals($passPassTypeIdentifier, $pass->getPassTypeIdentifier());
 }