setLongQueryTime 當 Query 時間超過這個時間時,會噴出 Warning log
public static setLongQueryTime ( integer $second = 1 ) : void | ||
$second | integer | |
Résultat | void |
/** * 測試 LongQueryTime 是否能正常讀取寫入 */ public function testSetLongQueryTime() { Pix_Table::setLongQueryTime(); $this->assertEquals(Pix_Table::getLongQueryTime(), 1); Pix_Table::setLongQueryTime(100); $this->assertEquals(Pix_Table::getLongQueryTime(), 100); Pix_Table::setLongQueryTime(0); $this->assertEquals(Pix_Table::getLongQueryTime(), 0); Pix_Table::setLongQueryTime(); $this->assertEquals(Pix_Table::getLongQueryTime(), 1); }