Use assertInstanceOf instead of manual testing
This commit is contained in:
parent
5ef6f6a98c
commit
ff16e8bdd0
@ -99,7 +99,10 @@ class PMA_DBQbe_test extends PHPUnit_Framework_TestCase
|
||||
* Test for getCommonFunctions
|
||||
*/
|
||||
public function testGetCommonFunctions(){
|
||||
$this->assertTrue($this->object->getCommonFunctions() instanceof PMA_CommonFunctions);
|
||||
$this->assertInstanceOf(
|
||||
'PMA_CommonFunctions',
|
||||
$this->object->getCommonFunctions()
|
||||
);
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
@ -76,7 +76,10 @@ class PMA_DbSearch_test extends PHPUnit_Framework_TestCase
|
||||
* Test for getCommonFunctions
|
||||
*/
|
||||
public function testGetCommonFunctions(){
|
||||
$this->assertTrue($this->object->getCommonFunctions() instanceof PMA_CommonFunctions);
|
||||
$this->assertInstanceOf(
|
||||
'PMA_CommonFunctions',
|
||||
$this->object->getCommonFunctions()
|
||||
);
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
@ -101,7 +101,10 @@ class PMA_Theme_Manager_test extends PHPUnit_Framework_TestCase
|
||||
*/
|
||||
public function testGetFallBackTheme(){
|
||||
$tm = new PMA_Theme_Manager();
|
||||
$this->assertTrue($tm->getFallBackTheme() instanceof PMA_Theme);
|
||||
$this->assertInstanceOf(
|
||||
'PMA_theme',
|
||||
$tm->getFallBackTheme()
|
||||
);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@ -236,7 +236,7 @@ class PMA_GIS_Geometrycollection_test extends PHPUnit_Framework_TestCase
|
||||
$return = $this->object->prepareRowAsPdf(
|
||||
$spatial, $label, $line_color, $scale_data, $pdf
|
||||
);
|
||||
$this->assertTrue($return instanceof TCPDF);
|
||||
$this->assertInstanceOf('TCPDF', $return);
|
||||
}
|
||||
|
||||
public function providerForPrepareRowAsPdf()
|
||||
|
||||
@ -220,7 +220,7 @@ class PMA_GIS_LinestringTest extends PMA_GIS_GeomTest
|
||||
$return = $this->object->prepareRowAsPdf(
|
||||
$spatial, $label, $line_color, $scale_data, $pdf
|
||||
);
|
||||
$this->assertTrue($return instanceof TCPDF);
|
||||
$this->assertInstanceOf('TCPDF', $return);
|
||||
}
|
||||
|
||||
public function providerForPrepareRowAsPdf()
|
||||
|
||||
@ -276,7 +276,7 @@ class PMA_GIS_MultilinestringTest extends PMA_GIS_GeomTest
|
||||
{
|
||||
|
||||
$return = $this->object->prepareRowAsPdf($spatial, $label, $line_color, $scale_data, $pdf);
|
||||
$this->assertTrue($return instanceof TCPDF);
|
||||
$this->assertInstanceOf('TCPDF', $return);
|
||||
}
|
||||
|
||||
public function providerForPrepareRowAsPdf(){
|
||||
|
||||
@ -220,7 +220,7 @@ class PMA_GIS_MultipointTest extends PMA_GIS_GeomTest
|
||||
{
|
||||
|
||||
$return = $this->object->prepareRowAsPdf($spatial, $label, $line_color, $scale_data, $pdf);
|
||||
$this->assertTrue($return instanceof TCPDF);
|
||||
$this->assertInstanceOf('TCPDF', $return);
|
||||
}
|
||||
|
||||
public function providerForPrepareRowAsPdf(){
|
||||
|
||||
@ -314,7 +314,7 @@ class PMA_GIS_MultipolygonTest extends PMA_GIS_GeomTest
|
||||
{
|
||||
|
||||
$return = $this->object->prepareRowAsPdf($spatial, $label, $line_color, $scale_data, $pdf);
|
||||
$this->assertTrue($return instanceof TCPDF);
|
||||
$this->assertInstanceOf('TCPDF', $return);
|
||||
}
|
||||
|
||||
public function providerForPrepareRowAsPdf(){
|
||||
|
||||
@ -222,7 +222,7 @@ class PMA_GIS_PointTest extends PMA_GIS_GeomTest
|
||||
{
|
||||
|
||||
$return = $this->object->prepareRowAsPdf($spatial, $label, $line_color, $scale_data, $pdf);
|
||||
$this->assertTrue($return instanceof TCPDF);
|
||||
$this->assertInstanceOf('TCPDF', $return);
|
||||
}
|
||||
|
||||
public function providerForPrepareRowAsPdf(){
|
||||
|
||||
@ -402,7 +402,7 @@ class PMA_GIS_PolygonTest extends PMA_GIS_GeomTest
|
||||
{
|
||||
|
||||
$return = $this->object->prepareRowAsPdf($spatial, $label, $line_color, $scale_data, $pdf);
|
||||
$this->assertTrue($return instanceof TCPDF);
|
||||
$this->assertInstanceOf('TCPDF', $return);
|
||||
}
|
||||
|
||||
public function providerForPrepareRowAsPdf(){
|
||||
|
||||
Loading…
Reference in New Issue
Block a user