Skip to content

Commit 169c488

Browse files
committed
Add a test for null getDBFHeader
Signed-off-by: William Desportes <[email protected]>
1 parent 2eecfdd commit 169c488

File tree

1 file changed

+9
-0
lines changed

1 file changed

+9
-0
lines changed

tests/ShapeFileTest.php

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -124,6 +124,15 @@ public function testLoadEmptyFilename(): void
124124
$this->assertEquals('Not a SHP file (file code mismatch)', $shp->lastError);
125125
}
126126

127+
/**
128+
* Test to call getDBFHeader on a non loaded file
129+
*/
130+
public function testGetDBFHeader(): void
131+
{
132+
$shp = new ShapeFile(1);
133+
$this->assertNull($shp->getDBFHeader());
134+
}
135+
127136
/**
128137
* Data provider for file loading error tests.
129138
*

0 commit comments

Comments
 (0)