mirror of
https://github.com/PHPOffice/PhpSpreadsheet.git
synced 2026-09-20 07:09:21 +00:00
1b05dfab8b
And quite a bit more manual changes. The idea is that typing of our tests can be a bit more loose, so we assume PHPDoc is mostly correct. If that happens to be wrong, it should be caught by the tests themselves.
30 lines
777 B
PHP
30 lines
777 B
PHP
<?php
|
|
|
|
namespace PhpOffice\PhpSpreadsheetTests\Calculation\Functions\LookupRef;
|
|
|
|
use PhpOffice\PhpSpreadsheet\Calculation\Functions;
|
|
use PhpOffice\PhpSpreadsheet\Calculation\LookupRef;
|
|
use PHPUnit\Framework\TestCase;
|
|
|
|
class TransposeTest extends TestCase
|
|
{
|
|
protected function setUp(): void
|
|
{
|
|
Functions::setCompatibilityMode(Functions::COMPATIBILITY_EXCEL);
|
|
}
|
|
|
|
/**
|
|
* @dataProvider providerTRANSPOSE
|
|
*/
|
|
public function testTRANSPOSE(mixed $expectedResult, mixed $matrix): void
|
|
{
|
|
$result = LookupRef\Matrix::transpose($matrix);
|
|
self::assertEquals($expectedResult, $result);
|
|
}
|
|
|
|
public static function providerTRANSPOSE(): array
|
|
{
|
|
return require 'tests/data/Calculation/LookupRef/TRANSPOSE.php';
|
|
}
|
|
}
|