public function testCampaignInactivation() { $c = Factory::cc(false); $this->assertFalse($c->isActive()); $c->activate(); $this->assertTrue($c->isActive()); }
public function testScriptIsIIFE() { $c = Factory::cc(); $generator = new FancyboxAjaxGenerator('http://test.lcl/testpopup.php'); $js = $generator->getScript($c, "URL", 1); $trimmedJs = trim($js); $this->assertNotEquals(false, strpos($trimmedJs, '(function () {')); $this->assertNotEquals(false, strpos($trimmedJs, '());')); }