function testAddKeyword() { $this->assertTrue($this->item->addKeyword(1)); $this->db->executeSQL("SELECT * FROM m2m_keywords_to_google_ad_groups WHERE gag_id = " . $this->item->gag_id . " and keyword_id = 1", $resultArry, $rowsAffected); $this->assertTrue($rowsAffected > 0); $bck = $this->item->gag_id; $this->item->gag_id = ''; $this->assertFalse($this->item->addKeyword(1)); $this->item->gag_id = $bck; $this->assertFalse($this->item->addKeyword()); }