Dshafik\MySQL\Tests\MySqlShimTest::test_mysql_affected_rows PHP Method

test_mysql_affected_rows() public method

    public function test_mysql_affected_rows()
    {
        $this->getConnection("shim_test");
        $result = mysql_query("UPDATE testing SET one = one + 1000, two = two + 1000 ORDER BY one DESC LIMIT 4");
        $this->assertTrue($result);
        $this->assertEquals(4, mysql_affected_rows());
        $result = mysql_query("UPDATE testing SET one = one - 1000, two = two - 1000 ORDER BY one DESC LIMIT 4");
        $this->assertTrue($result, mysql_error());
        $this->assertEquals(4, mysql_affected_rows());
    }
MySqlShimTest