/** * Tests that defaults get set correctly when instantiating **/ public function testCalendarInitializeDefaults() { $component = new qCal_Component_Vcalendar(); $component->validate(); // test calendar defaults. eventually there will be convenience methods // that will allow you to do $component->prodid() to get and set $prodid = $component->getProperty('prodid'); $this->assertEqual($prodid[0]->getValue(), '-//Luke Visinoni//qCal v0.1//EN'); $version = $component->getProperty('version'); $this->assertEqual($version[0]->getValue(), '2.0'); // I commented this out because as of right now I Don't need a component factory // do it through factory too //$component = qCal_Component::factory('VCALENDAR'); //$this->assertEqual($component->getProperty('prodid')->getValue(), '-//Luke Visinoni//qCal v0.1//EN'); //$this->assertEqual($component->getProperty('version')->getValue(), '2.0'); }