| 
									
										
										
										
											2012-07-29 19:56:35 +00:00
										 |  |  | <?php | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  | require_once 'testDataFileIterator.php'; | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  | class CellTest extends PHPUnit_Framework_TestCase | 
					
						
							|  |  |  | { | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  |     public function setUp() | 
					
						
							|  |  |  |     { | 
					
						
							|  |  |  |         if (!defined('PHPEXCEL_ROOT')) { | 
					
						
							|  |  |  |             define('PHPEXCEL_ROOT', APPLICATION_PATH . '/'); | 
					
						
							|  |  |  |         } | 
					
						
							|  |  |  |         require_once(PHPEXCEL_ROOT . 'PHPExcel/Autoloader.php'); | 
					
						
							| 
									
										
										
										
											2015-05-17 13:00:02 +00:00
										 |  |  |     } | 
					
						
							| 
									
										
										
										
											2012-07-29 19:56:35 +00:00
										 |  |  | 
 | 
					
						
							|  |  |  |     /** | 
					
						
							|  |  |  |      * @dataProvider providerColumnString | 
					
						
							|  |  |  |      */ | 
					
						
							| 
									
										
										
										
											2015-05-17 13:00:02 +00:00
										 |  |  |     public function testColumnIndexFromString() | 
					
						
							|  |  |  |     { | 
					
						
							|  |  |  |         $args = func_get_args(); | 
					
						
							|  |  |  |         $expectedResult = array_pop($args); | 
					
						
							| 
									
										
										
										
											2015-05-17 16:34:30 +00:00
										 |  |  |         $result = call_user_func_array(array('PHPExcel_Cell','columnIndexFromString'), $args); | 
					
						
							| 
									
										
										
										
											2015-05-17 13:00:02 +00:00
										 |  |  |         $this->assertEquals($expectedResult, $result); | 
					
						
							|  |  |  |     } | 
					
						
							| 
									
										
										
										
											2012-07-29 19:56:35 +00:00
										 |  |  | 
 | 
					
						
							|  |  |  |     public function providerColumnString() | 
					
						
							|  |  |  |     { | 
					
						
							| 
									
										
										
										
											2015-05-17 13:00:02 +00:00
										 |  |  |         return new testDataFileIterator('rawTestData/ColumnString.data'); | 
					
						
							|  |  |  |     } | 
					
						
							| 
									
										
										
										
											2012-07-29 19:56:35 +00:00
										 |  |  | 
 | 
					
						
							|  |  |  |     public function testColumnIndexFromStringTooLong() | 
					
						
							| 
									
										
										
										
											2015-05-17 13:00:02 +00:00
										 |  |  |     { | 
					
						
							|  |  |  |         $cellAddress = 'ABCD'; | 
					
						
							|  |  |  |         try { | 
					
						
							| 
									
										
										
										
											2015-05-17 16:34:30 +00:00
										 |  |  |             $result = call_user_func(array('PHPExcel_Cell','columnIndexFromString'), $cellAddress); | 
					
						
							| 
									
										
										
										
											2015-05-17 13:00:02 +00:00
										 |  |  |         } catch (PHPExcel_Exception $e) { | 
					
						
							|  |  |  |             $this->assertEquals($e->getMessage(), 'Column string index can not be longer than 3 characters'); | 
					
						
							|  |  |  |             return; | 
					
						
							|  |  |  |         } | 
					
						
							|  |  |  |         $this->fail('An expected exception has not been raised.'); | 
					
						
							|  |  |  |     } | 
					
						
							| 
									
										
										
										
											2012-07-29 19:56:35 +00:00
										 |  |  | 
 | 
					
						
							|  |  |  |     public function testColumnIndexFromStringTooShort() | 
					
						
							| 
									
										
										
										
											2015-05-17 13:00:02 +00:00
										 |  |  |     { | 
					
						
							|  |  |  |         $cellAddress = ''; | 
					
						
							|  |  |  |         try { | 
					
						
							| 
									
										
										
										
											2015-05-17 16:34:30 +00:00
										 |  |  |             $result = call_user_func(array('PHPExcel_Cell','columnIndexFromString'), $cellAddress); | 
					
						
							| 
									
										
										
										
											2015-05-17 13:00:02 +00:00
										 |  |  |         } catch (PHPExcel_Exception $e) { | 
					
						
							|  |  |  |             $this->assertEquals($e->getMessage(), 'Column string index can not be empty'); | 
					
						
							|  |  |  |             return; | 
					
						
							|  |  |  |         } | 
					
						
							|  |  |  |         $this->fail('An expected exception has not been raised.'); | 
					
						
							|  |  |  |     } | 
					
						
							| 
									
										
										
										
											2012-07-29 19:56:35 +00:00
										 |  |  | 
 | 
					
						
							|  |  |  |     /** | 
					
						
							|  |  |  |      * @dataProvider providerColumnIndex | 
					
						
							|  |  |  |      */ | 
					
						
							| 
									
										
										
										
											2015-05-17 13:00:02 +00:00
										 |  |  |     public function testStringFromColumnIndex() | 
					
						
							|  |  |  |     { | 
					
						
							|  |  |  |         $args = func_get_args(); | 
					
						
							|  |  |  |         $expectedResult = array_pop($args); | 
					
						
							| 
									
										
										
										
											2015-05-17 16:34:30 +00:00
										 |  |  |         $result = call_user_func_array(array('PHPExcel_Cell','stringFromColumnIndex'), $args); | 
					
						
							| 
									
										
										
										
											2015-05-17 13:00:02 +00:00
										 |  |  |         $this->assertEquals($expectedResult, $result); | 
					
						
							|  |  |  |     } | 
					
						
							| 
									
										
										
										
											2012-07-29 19:56:35 +00:00
										 |  |  | 
 | 
					
						
							|  |  |  |     public function providerColumnIndex() | 
					
						
							|  |  |  |     { | 
					
						
							| 
									
										
										
										
											2015-05-17 13:00:02 +00:00
										 |  |  |         return new testDataFileIterator('rawTestData/ColumnIndex.data'); | 
					
						
							|  |  |  |     } | 
					
						
							| 
									
										
										
										
											2012-07-29 19:56:35 +00:00
										 |  |  | 
 | 
					
						
							|  |  |  |     /** | 
					
						
							|  |  |  |      * @dataProvider providerCoordinates | 
					
						
							|  |  |  |      */ | 
					
						
							| 
									
										
										
										
											2015-05-17 13:00:02 +00:00
										 |  |  |     public function testCoordinateFromString() | 
					
						
							|  |  |  |     { | 
					
						
							|  |  |  |         $args = func_get_args(); | 
					
						
							|  |  |  |         $expectedResult = array_pop($args); | 
					
						
							| 
									
										
										
										
											2015-05-17 16:34:30 +00:00
										 |  |  |         $result = call_user_func_array(array('PHPExcel_Cell','coordinateFromString'), $args); | 
					
						
							| 
									
										
										
										
											2015-05-17 13:00:02 +00:00
										 |  |  |         $this->assertEquals($expectedResult, $result); | 
					
						
							|  |  |  |     } | 
					
						
							| 
									
										
										
										
											2012-07-29 19:56:35 +00:00
										 |  |  | 
 | 
					
						
							|  |  |  |     public function providerCoordinates() | 
					
						
							|  |  |  |     { | 
					
						
							| 
									
										
										
										
											2015-05-17 13:00:02 +00:00
										 |  |  |         return new testDataFileIterator('rawTestData/CellCoordinates.data'); | 
					
						
							|  |  |  |     } | 
					
						
							| 
									
										
										
										
											2012-07-29 19:56:35 +00:00
										 |  |  | 
 | 
					
						
							|  |  |  |     public function testCoordinateFromStringWithRangeAddress() | 
					
						
							| 
									
										
										
										
											2015-05-17 13:00:02 +00:00
										 |  |  |     { | 
					
						
							|  |  |  |         $cellAddress = 'A1:AI2012'; | 
					
						
							|  |  |  |         try { | 
					
						
							| 
									
										
										
										
											2015-05-17 16:34:30 +00:00
										 |  |  |             $result = call_user_func(array('PHPExcel_Cell','coordinateFromString'), $cellAddress); | 
					
						
							| 
									
										
										
										
											2015-05-17 13:00:02 +00:00
										 |  |  |         } catch (PHPExcel_Exception $e) { | 
					
						
							|  |  |  |             $this->assertEquals($e->getMessage(), 'Cell coordinate string can not be a range of cells'); | 
					
						
							|  |  |  |             return; | 
					
						
							|  |  |  |         } | 
					
						
							|  |  |  |         $this->fail('An expected exception has not been raised.'); | 
					
						
							|  |  |  |     } | 
					
						
							| 
									
										
										
										
											2012-07-29 19:56:35 +00:00
										 |  |  | 
 | 
					
						
							|  |  |  |     public function testCoordinateFromStringWithEmptyAddress() | 
					
						
							| 
									
										
										
										
											2015-05-17 13:00:02 +00:00
										 |  |  |     { | 
					
						
							|  |  |  |         $cellAddress = ''; | 
					
						
							|  |  |  |         try { | 
					
						
							| 
									
										
										
										
											2015-05-17 16:34:30 +00:00
										 |  |  |             $result = call_user_func(array('PHPExcel_Cell','coordinateFromString'), $cellAddress); | 
					
						
							| 
									
										
										
										
											2015-05-17 13:00:02 +00:00
										 |  |  |         } catch (PHPExcel_Exception $e) { | 
					
						
							|  |  |  |             $this->assertEquals($e->getMessage(), 'Cell coordinate can not be zero-length string'); | 
					
						
							|  |  |  |             return; | 
					
						
							|  |  |  |         } | 
					
						
							|  |  |  |         $this->fail('An expected exception has not been raised.'); | 
					
						
							|  |  |  |     } | 
					
						
							| 
									
										
										
										
											2012-07-29 19:56:35 +00:00
										 |  |  | 
 | 
					
						
							|  |  |  |     public function testCoordinateFromStringWithInvalidAddress() | 
					
						
							| 
									
										
										
										
											2015-05-17 13:00:02 +00:00
										 |  |  |     { | 
					
						
							|  |  |  |         $cellAddress = 'AI'; | 
					
						
							|  |  |  |         try { | 
					
						
							| 
									
										
										
										
											2015-05-17 16:34:30 +00:00
										 |  |  |             $result = call_user_func(array('PHPExcel_Cell','coordinateFromString'), $cellAddress); | 
					
						
							| 
									
										
										
										
											2015-05-17 13:00:02 +00:00
										 |  |  |         } catch (PHPExcel_Exception $e) { | 
					
						
							|  |  |  |             $this->assertEquals($e->getMessage(), 'Invalid cell coordinate '.$cellAddress); | 
					
						
							|  |  |  |             return; | 
					
						
							|  |  |  |         } | 
					
						
							|  |  |  |         $this->fail('An expected exception has not been raised.'); | 
					
						
							|  |  |  |     } | 
					
						
							| 
									
										
										
										
											2012-07-29 19:56:35 +00:00
										 |  |  | 
 | 
					
						
							|  |  |  |     /** | 
					
						
							|  |  |  |      * @dataProvider providerAbsoluteCoordinates | 
					
						
							|  |  |  |      */ | 
					
						
							| 
									
										
										
										
											2015-05-17 13:00:02 +00:00
										 |  |  |     public function testAbsoluteCoordinateFromString() | 
					
						
							|  |  |  |     { | 
					
						
							|  |  |  |         $args = func_get_args(); | 
					
						
							|  |  |  |         $expectedResult = array_pop($args); | 
					
						
							| 
									
										
										
										
											2015-05-17 16:34:30 +00:00
										 |  |  |         $result = call_user_func_array(array('PHPExcel_Cell','absoluteCoordinate'), $args); | 
					
						
							| 
									
										
										
										
											2015-05-17 13:00:02 +00:00
										 |  |  |         $this->assertEquals($expectedResult, $result); | 
					
						
							|  |  |  |     } | 
					
						
							| 
									
										
										
										
											2012-07-29 19:56:35 +00:00
										 |  |  | 
 | 
					
						
							|  |  |  |     public function providerAbsoluteCoordinates() | 
					
						
							|  |  |  |     { | 
					
						
							| 
									
										
										
										
											2015-05-17 13:00:02 +00:00
										 |  |  |         return new testDataFileIterator('rawTestData/CellAbsoluteCoordinate.data'); | 
					
						
							|  |  |  |     } | 
					
						
							| 
									
										
										
										
											2012-07-29 19:56:35 +00:00
										 |  |  | 
 | 
					
						
							|  |  |  |     public function testAbsoluteCoordinateFromStringWithRangeAddress() | 
					
						
							| 
									
										
										
										
											2015-05-17 13:00:02 +00:00
										 |  |  |     { | 
					
						
							|  |  |  |         $cellAddress = 'A1:AI2012'; | 
					
						
							|  |  |  |         try { | 
					
						
							| 
									
										
										
										
											2015-05-17 16:34:30 +00:00
										 |  |  |             $result = call_user_func(array('PHPExcel_Cell','absoluteCoordinate'), $cellAddress); | 
					
						
							| 
									
										
										
										
											2015-05-17 13:00:02 +00:00
										 |  |  |         } catch (PHPExcel_Exception $e) { | 
					
						
							|  |  |  |             $this->assertEquals($e->getMessage(), 'Cell coordinate string can not be a range of cells'); | 
					
						
							|  |  |  |             return; | 
					
						
							|  |  |  |         } | 
					
						
							|  |  |  |         $this->fail('An expected exception has not been raised.'); | 
					
						
							|  |  |  |     } | 
					
						
							| 
									
										
										
										
											2012-07-29 19:56:35 +00:00
										 |  |  | 
 | 
					
						
							|  |  |  |     /** | 
					
						
							|  |  |  |      * @dataProvider providerAbsoluteReferences | 
					
						
							|  |  |  |      */ | 
					
						
							| 
									
										
										
										
											2015-05-17 13:00:02 +00:00
										 |  |  |     public function testAbsoluteReferenceFromString() | 
					
						
							|  |  |  |     { | 
					
						
							|  |  |  |         $args = func_get_args(); | 
					
						
							|  |  |  |         $expectedResult = array_pop($args); | 
					
						
							| 
									
										
										
										
											2015-05-17 16:34:30 +00:00
										 |  |  |         $result = call_user_func_array(array('PHPExcel_Cell','absoluteReference'), $args); | 
					
						
							| 
									
										
										
										
											2015-05-17 13:00:02 +00:00
										 |  |  |         $this->assertEquals($expectedResult, $result); | 
					
						
							|  |  |  |     } | 
					
						
							| 
									
										
										
										
											2012-07-29 19:56:35 +00:00
										 |  |  | 
 | 
					
						
							|  |  |  |     public function providerAbsoluteReferences() | 
					
						
							|  |  |  |     { | 
					
						
							| 
									
										
										
										
											2015-05-17 13:00:02 +00:00
										 |  |  |         return new testDataFileIterator('rawTestData/CellAbsoluteReference.data'); | 
					
						
							|  |  |  |     } | 
					
						
							| 
									
										
										
										
											2012-07-29 19:56:35 +00:00
										 |  |  | 
 | 
					
						
							|  |  |  |     public function testAbsoluteReferenceFromStringWithRangeAddress() | 
					
						
							| 
									
										
										
										
											2015-05-17 13:00:02 +00:00
										 |  |  |     { | 
					
						
							|  |  |  |         $cellAddress = 'A1:AI2012'; | 
					
						
							|  |  |  |         try { | 
					
						
							| 
									
										
										
										
											2015-05-17 16:34:30 +00:00
										 |  |  |             $result = call_user_func(array('PHPExcel_Cell','absoluteReference'), $cellAddress); | 
					
						
							| 
									
										
										
										
											2015-05-17 13:00:02 +00:00
										 |  |  |         } catch (PHPExcel_Exception $e) { | 
					
						
							|  |  |  |             $this->assertEquals($e->getMessage(), 'Cell coordinate string can not be a range of cells'); | 
					
						
							|  |  |  |             return; | 
					
						
							|  |  |  |         } | 
					
						
							|  |  |  |         $this->fail('An expected exception has not been raised.'); | 
					
						
							|  |  |  |     } | 
					
						
							| 
									
										
										
										
											2012-07-29 19:56:35 +00:00
										 |  |  | 
 | 
					
						
							|  |  |  |     /** | 
					
						
							|  |  |  |      * @dataProvider providerSplitRange | 
					
						
							|  |  |  |      */ | 
					
						
							| 
									
										
										
										
											2015-05-17 13:00:02 +00:00
										 |  |  |     public function testSplitRange() | 
					
						
							|  |  |  |     { | 
					
						
							|  |  |  |         $args = func_get_args(); | 
					
						
							|  |  |  |         $expectedResult = array_pop($args); | 
					
						
							| 
									
										
										
										
											2015-05-17 16:34:30 +00:00
										 |  |  |         $result = call_user_func_array(array('PHPExcel_Cell','splitRange'), $args); | 
					
						
							| 
									
										
										
										
											2015-05-17 13:00:02 +00:00
										 |  |  |         foreach ($result as $key => $split) { | 
					
						
							|  |  |  |             if (!is_array($expectedResult[$key])) { | 
					
						
							|  |  |  |                 $this->assertEquals($expectedResult[$key], $split[0]); | 
					
						
							|  |  |  |             } else { | 
					
						
							|  |  |  |                 $this->assertEquals($expectedResult[$key], $split); | 
					
						
							|  |  |  |             } | 
					
						
							|  |  |  |         } | 
					
						
							|  |  |  |     } | 
					
						
							| 
									
										
										
										
											2012-07-29 19:56:35 +00:00
										 |  |  | 
 | 
					
						
							|  |  |  |     public function providerSplitRange() | 
					
						
							|  |  |  |     { | 
					
						
							| 
									
										
										
										
											2015-05-17 13:00:02 +00:00
										 |  |  |         return new testDataFileIterator('rawTestData/CellSplitRange.data'); | 
					
						
							|  |  |  |     } | 
					
						
							| 
									
										
										
										
											2012-07-29 19:56:35 +00:00
										 |  |  | 
 | 
					
						
							|  |  |  |     /** | 
					
						
							|  |  |  |      * @dataProvider providerBuildRange | 
					
						
							|  |  |  |      */ | 
					
						
							| 
									
										
										
										
											2015-05-17 13:00:02 +00:00
										 |  |  |     public function testBuildRange() | 
					
						
							|  |  |  |     { | 
					
						
							|  |  |  |         $args = func_get_args(); | 
					
						
							|  |  |  |         $expectedResult = array_pop($args); | 
					
						
							| 
									
										
										
										
											2015-05-17 16:34:30 +00:00
										 |  |  |         $result = call_user_func_array(array('PHPExcel_Cell','buildRange'), $args); | 
					
						
							| 
									
										
										
										
											2015-05-17 13:00:02 +00:00
										 |  |  |         $this->assertEquals($expectedResult, $result); | 
					
						
							|  |  |  |     } | 
					
						
							| 
									
										
										
										
											2012-07-29 19:56:35 +00:00
										 |  |  | 
 | 
					
						
							|  |  |  |     public function providerBuildRange() | 
					
						
							|  |  |  |     { | 
					
						
							| 
									
										
										
										
											2015-05-17 13:00:02 +00:00
										 |  |  |         return new testDataFileIterator('rawTestData/CellBuildRange.data'); | 
					
						
							|  |  |  |     } | 
					
						
							| 
									
										
										
										
											2012-07-29 19:56:35 +00:00
										 |  |  | 
 | 
					
						
							|  |  |  |     public function testBuildRangeInvalid() | 
					
						
							| 
									
										
										
										
											2015-05-17 13:00:02 +00:00
										 |  |  |     { | 
					
						
							|  |  |  |         $cellRange = ''; | 
					
						
							|  |  |  |         try { | 
					
						
							| 
									
										
										
										
											2015-05-17 16:34:30 +00:00
										 |  |  |             $result = call_user_func(array('PHPExcel_Cell','buildRange'), $cellRange); | 
					
						
							| 
									
										
										
										
											2015-05-17 13:00:02 +00:00
										 |  |  |         } catch (PHPExcel_Exception $e) { | 
					
						
							|  |  |  |             $this->assertEquals($e->getMessage(), 'Range does not contain any information'); | 
					
						
							|  |  |  |             return; | 
					
						
							|  |  |  |         } | 
					
						
							|  |  |  |         $this->fail('An expected exception has not been raised.'); | 
					
						
							|  |  |  |     } | 
					
						
							| 
									
										
										
										
											2012-07-29 19:56:35 +00:00
										 |  |  | 
 | 
					
						
							|  |  |  |     /** | 
					
						
							|  |  |  |      * @dataProvider providerRangeBoundaries | 
					
						
							|  |  |  |      */ | 
					
						
							| 
									
										
										
										
											2015-05-17 13:00:02 +00:00
										 |  |  |     public function testRangeBoundaries() | 
					
						
							|  |  |  |     { | 
					
						
							|  |  |  |         $args = func_get_args(); | 
					
						
							|  |  |  |         $expectedResult = array_pop($args); | 
					
						
							| 
									
										
										
										
											2015-05-17 16:34:30 +00:00
										 |  |  |         $result = call_user_func_array(array('PHPExcel_Cell','rangeBoundaries'), $args); | 
					
						
							| 
									
										
										
										
											2015-05-17 13:00:02 +00:00
										 |  |  |         $this->assertEquals($expectedResult, $result); | 
					
						
							|  |  |  |     } | 
					
						
							| 
									
										
										
										
											2012-07-29 19:56:35 +00:00
										 |  |  | 
 | 
					
						
							|  |  |  |     public function providerRangeBoundaries() | 
					
						
							|  |  |  |     { | 
					
						
							| 
									
										
										
										
											2015-05-17 13:00:02 +00:00
										 |  |  |         return new testDataFileIterator('rawTestData/CellRangeBoundaries.data'); | 
					
						
							|  |  |  |     } | 
					
						
							| 
									
										
										
										
											2012-07-29 19:56:35 +00:00
										 |  |  | 
 | 
					
						
							|  |  |  |     /** | 
					
						
							|  |  |  |      * @dataProvider providerRangeDimension | 
					
						
							|  |  |  |      */ | 
					
						
							| 
									
										
										
										
											2015-05-17 13:00:02 +00:00
										 |  |  |     public function testRangeDimension() | 
					
						
							|  |  |  |     { | 
					
						
							|  |  |  |         $args = func_get_args(); | 
					
						
							|  |  |  |         $expectedResult = array_pop($args); | 
					
						
							| 
									
										
										
										
											2015-05-17 16:34:30 +00:00
										 |  |  |         $result = call_user_func_array(array('PHPExcel_Cell','rangeDimension'), $args); | 
					
						
							| 
									
										
										
										
											2015-05-17 13:00:02 +00:00
										 |  |  |         $this->assertEquals($expectedResult, $result); | 
					
						
							|  |  |  |     } | 
					
						
							| 
									
										
										
										
											2012-07-29 19:56:35 +00:00
										 |  |  | 
 | 
					
						
							|  |  |  |     public function providerRangeDimension() | 
					
						
							|  |  |  |     { | 
					
						
							| 
									
										
										
										
											2015-05-17 13:00:02 +00:00
										 |  |  |         return new testDataFileIterator('rawTestData/CellRangeDimension.data'); | 
					
						
							|  |  |  |     } | 
					
						
							| 
									
										
										
										
											2012-07-29 19:56:35 +00:00
										 |  |  | 
 | 
					
						
							| 
									
										
										
										
											2012-07-31 12:00:09 +00:00
										 |  |  |     /** | 
					
						
							|  |  |  |      * @dataProvider providerGetRangeBoundaries | 
					
						
							|  |  |  |      */ | 
					
						
							| 
									
										
										
										
											2015-05-17 13:00:02 +00:00
										 |  |  |     public function testGetRangeBoundaries() | 
					
						
							|  |  |  |     { | 
					
						
							|  |  |  |         $args = func_get_args(); | 
					
						
							|  |  |  |         $expectedResult = array_pop($args); | 
					
						
							| 
									
										
										
										
											2015-05-17 16:34:30 +00:00
										 |  |  |         $result = call_user_func_array(array('PHPExcel_Cell','getRangeBoundaries'), $args); | 
					
						
							| 
									
										
										
										
											2015-05-17 13:00:02 +00:00
										 |  |  |         $this->assertEquals($expectedResult, $result); | 
					
						
							|  |  |  |     } | 
					
						
							| 
									
										
										
										
											2012-07-31 12:00:09 +00:00
										 |  |  | 
 | 
					
						
							|  |  |  |     public function providerGetRangeBoundaries() | 
					
						
							|  |  |  |     { | 
					
						
							| 
									
										
										
										
											2015-05-17 13:00:02 +00:00
										 |  |  |         return new testDataFileIterator('rawTestData/CellGetRangeBoundaries.data'); | 
					
						
							|  |  |  |     } | 
					
						
							| 
									
										
										
										
											2012-07-31 12:00:09 +00:00
										 |  |  | 
 | 
					
						
							|  |  |  |     /** | 
					
						
							|  |  |  |      * @dataProvider providerExtractAllCellReferencesInRange | 
					
						
							|  |  |  |      */ | 
					
						
							| 
									
										
										
										
											2015-05-17 13:00:02 +00:00
										 |  |  |     public function testExtractAllCellReferencesInRange() | 
					
						
							|  |  |  |     { | 
					
						
							|  |  |  |         $args = func_get_args(); | 
					
						
							|  |  |  |         $expectedResult = array_pop($args); | 
					
						
							| 
									
										
										
										
											2015-05-17 16:34:30 +00:00
										 |  |  |         $result = call_user_func_array(array('PHPExcel_Cell','extractAllCellReferencesInRange'), $args); | 
					
						
							| 
									
										
										
										
											2015-05-17 13:00:02 +00:00
										 |  |  |         $this->assertEquals($expectedResult, $result); | 
					
						
							|  |  |  |     } | 
					
						
							| 
									
										
										
										
											2012-07-31 12:00:09 +00:00
										 |  |  | 
 | 
					
						
							|  |  |  |     public function providerExtractAllCellReferencesInRange() | 
					
						
							|  |  |  |     { | 
					
						
							| 
									
										
										
										
											2015-05-17 13:00:02 +00:00
										 |  |  |         return new testDataFileIterator('rawTestData/CellExtractAllCellReferencesInRange.data'); | 
					
						
							|  |  |  |     } | 
					
						
							| 
									
										
										
										
											2012-07-29 19:56:35 +00:00
										 |  |  | } |