| Conditions | 1 |
| Paths | 1 |
| Total Lines | 38 |
| Code Lines | 28 |
| Lines | 0 |
| Ratio | 0 % |
| Changes | 0 | ||
| 1 | <?php |
||
| 20 | public function testReIndexPerformsCombineKeysInPlace() |
||
| 21 | { |
||
| 22 | $coll = Factory::create($this->fixtures['names']); |
||
| 23 | |||
| 24 | $this->assertEquals( |
||
| 25 | [ |
||
| 26 | 'Chelsea', |
||
| 27 | 'Adella', |
||
| 28 | 'Monte', |
||
| 29 | 'Maye', |
||
| 30 | 'Lottie', |
||
| 31 | 'Don', |
||
| 32 | 'Dayton', |
||
| 33 | 'Kirk', |
||
| 34 | 'Troy', |
||
| 35 | 'Nakia', |
||
| 36 | ], |
||
| 37 | $orig = $coll->toArray() |
||
| 38 | ); |
||
| 39 | |||
| 40 | $return = $coll->reindex($this->fixtures['emails']); |
||
| 41 | $this->assertSame($coll, $return); |
||
| 42 | $this->assertSame( |
||
| 43 | [ |
||
| 44 | '[email protected]' => 'Chelsea', |
||
| 45 | '[email protected]' => 'Adella', |
||
| 46 | '[email protected]' => 'Monte', |
||
| 47 | '[email protected]' => 'Maye', |
||
| 48 | '[email protected]' => 'Lottie', |
||
| 49 | '[email protected]' => 'Don', |
||
| 50 | '[email protected]' => 'Dayton', |
||
| 51 | '[email protected]' => 'Kirk', |
||
| 52 | '[email protected]' => 'Troy', |
||
| 53 | '[email protected]' => 'Nakia', |
||
| 54 | ], |
||
| 55 | $return->toArray() |
||
| 56 | ); |
||
| 57 | } |
||
| 58 | } |
||
| 59 |