Add and improve test coverage
This commit is contained in:
1 parent
2074781852
commit
3f3461b002
12 files changed
+146
-2
No files matched your search
@@ -13,6 +13,8 @@ class CSV implements EscaperInterface
|
||||
/**
|
||||
* Escapes the given string to make it compatible with CSV
|
||||
*
|
||||
* @codeCoverageIgnore
|
||||
*
|
||||
* @param string $string The string to escape
|
||||
* @return string The escaped string
|
||||
*/
|
||||
@@ -24,6 +26,8 @@ class CSV implements EscaperInterface
|
||||
/**
|
||||
* Unescapes the given string to make it compatible with CSV
|
||||
*
|
||||
* @codeCoverageIgnore
|
||||
*
|
||||
* @param string $string The string to unescape
|
||||
* @return string The unescaped string
|
||||
*/
|
||||
|
||||
@@ -6,6 +6,8 @@ namespace Box\Spout\Common\Helper;
|
||||
* Class GlobalFunctionsHelper
|
||||
* This class wraps global functions to facilitate testing
|
||||
*
|
||||
* @codeCoverageIgnore
|
||||
*
|
||||
* @package Box\Spout\Common\Helper
|
||||
*/
|
||||
class GlobalFunctionsHelper
|
||||
|
||||
@@ -25,7 +25,7 @@ class CellHelper
|
||||
{
|
||||
$existingIndexes = array_keys($dataArray);
|
||||
|
||||
$newIndexes = array_fill_keys(range(min($existingIndexes), max($existingIndexes)), $fillValue);
|
||||
$newIndexes = array_fill_keys(range(0, max($existingIndexes)), $fillValue);
|
||||
$dataArray += $newIndexes;
|
||||
|
||||
ksort($dataArray);
|
||||
|
||||
@@ -89,6 +89,8 @@ abstract class AbstractWriter implements WriterInterface
|
||||
* Inits the writer and opens it to accept data.
|
||||
* By using this method, the data will be outputted directly to the browser.
|
||||
*
|
||||
* @codeCoverageIgnore
|
||||
*
|
||||
* @param string $outputFileName Name of the output file that will contain the data. If a path is passed in, only the file name will be kept
|
||||
* @return \Box\Spout\Writer\AbstractWriter
|
||||
* @throws \Box\Spout\Common\Exception\IOException If the writer cannot be opened
|
||||
|
||||
Reference in new issue
Block a user