public function testSetCurrentCycleComplete() { $billingAgreement = new BillingAgreement(); $billingAgreement->setInitialBillingDate(new \DateTime('2012-10-10')); $billingAgreement->setBillingInterval('+1 month'); $billingAgreement->setNumberCyclesBilled(1); $this->assertEquals(1, $billingAgreement->getNumberCyclesBilled()); $billingAgreement = new BillingAgreement(); $billingAgreement->setInitialBillingDate(new \DateTime('2011-10-10')); $billingAgreement->setBillingInterval('+1 year'); $billingAgreement->setNumberCyclesBilled(2); $this->assertEquals(2, $billingAgreement->getNumberCyclesBilled()); $billingAgreement = new BillingAgreement(); $billingAgreement->setInitialBillingDate(new \DateTime('2012-12-29')); $billingAgreement->setBillingInterval('+1 month'); $billingAgreement->setNumberCyclesBilled(1); }