/**
  * Test the bindObject without array option
  */
 public function testBindObject()
 {
     $this->_owner = new Mock\Owner();
     $this->_owner->name = 'Sam';
     $this->_owner->age = 25;
     $query = PDOFactory::Get("INSERT INTO owners (name, age) VALUES (:name, :age)");
     $query->bindObject($this->_owner);
     $query->execute();
     $this->_owner->id = PDOFactory::LastInsertId();
     $owner = Mock\Owner::Find($this->_owner->id);
     $this->assertEquals('Sam', $owner->name);
 }
 public function testCreateWithAutoIncrement()
 {
     $owner = new Mock\Owner();
     $owner->name = 'Fred';
     $owner->age = rand(0, 120);
     $owner->species = 'Human';
     $owner->save();
     $retrieved = Mock\Owner::Find($owner->id());
     $this->assertEquals($owner->age, $retrieved->age);
 }