Ejemplo n.º 1
0
 /**
  * Create new Gnip Publisher -- with XML values -- then validate against returned string values.
  *
  * @access    public
  * @param     void
  * @return    void
  */
 function testFromXml()
 {
     $xml = '<rule type="actor" value="testActor"/>';
     $rule = Services_Gnip_Rule::fromXml(new SimpleXMLElement($xml));
     $this->assertEquals("actor", $rule->type);
     $this->assertEquals("testActor", $rule->value);
 }
Ejemplo n.º 2
0
 function testFromXml()
 {
     $xml = '<rule type="actor">testActor</rule>';
     $rule = Services_Gnip_Rule::fromXml($xml);
     $this->assertEquals("actor", $rule->type);
     $this->assertEquals("testActor", $rule->value);
 }