mirror of
https://github.com/parsecsv/parsecsv-for-php.git
synced 2026-02-19 08:36:39 +00:00
PHPUnit: Repaired file paths in autoQuotesDataProvider()
This commit is contained in:
@@ -152,8 +152,8 @@ class ParseTest extends PHPUnit\Framework\TestCase {
|
|||||||
|
|
||||||
public function autoQuotesDataProvider() {
|
public function autoQuotesDataProvider() {
|
||||||
return array(
|
return array(
|
||||||
array('tests/methods/fixtures/auto-double-enclosure.csv', '"'),
|
array('auto-double-enclosure.csv', '"'),
|
||||||
array('tests/methods/fixtures/auto-single-enclosure.csv', "'"),
|
array('auto-single-enclosure.csv', "'"),
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -165,7 +165,7 @@ class ParseTest extends PHPUnit\Framework\TestCase {
|
|||||||
*/
|
*/
|
||||||
public function testAutoQuotes($file, $enclosure) {
|
public function testAutoQuotes($file, $enclosure) {
|
||||||
$csv = new parseCSV();
|
$csv = new parseCSV();
|
||||||
$csv->auto($file, true, null, null, $enclosure);
|
$csv->auto(__DIR__ . '/../example_files/' . $file, true, null, null, $enclosure);
|
||||||
$this->assertArrayHasKey('column1', $csv->data[0], 'Data parsed incorrectly with enclosure ' . $enclosure);
|
$this->assertArrayHasKey('column1', $csv->data[0], 'Data parsed incorrectly with enclosure ' . $enclosure);
|
||||||
$this->assertEquals('value1', $csv->data[0]['column1'], 'Data parsed incorrectly with enclosure ' . $enclosure);
|
$this->assertEquals('value1', $csv->data[0]['column1'], 'Data parsed incorrectly with enclosure ' . $enclosure);
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user