Files
PhpSpreadsheet/tests/data/Calculation/Logical/AND.php
T
Adrien Crivelli ec4098c8fd Strict mode for all tests
While we might never be able to have 100% of our code strict, we can at
the very least do it for all of our tests. This ensures that our tests
are using our API with the types as intended by the test author, and not
silently be cast to what our API requires.
2023-09-07 17:44:56 +08:00

122 lines
1.6 KiB
PHP

<?php
declare(strict_types=1);
return [
'no arguments' => [
'exception',
],
'only argument is null reference' => [
'#VALUE!',
null,
],
// Boolean TRUE and NULL
[
true,
true,
null,
],
// Boolean FALSE and NULL
[
false,
false,
null,
],
// Both TRUE Booleans
[
true,
true,
true,
],
// Mixed Booleans
[
false,
true,
false,
],
// Mixed Booleans
[
false,
false,
true,
],
// Both FALSE Booleans
[
false,
false,
false,
],
// Multiple Mixed Booleans
[
false,
true,
true,
false,
],
// Multiple TRUE Booleans
[
true,
true,
true,
true,
],
// Multiple FALSE Booleans
[
false,
false,
false,
false,
false,
],
[
true,
-1,
-2,
],
[
false,
0,
0,
],
[
false,
0,
1,
],
[
true,
1,
1,
],
'string 1 is ignored' => [
true,
'1',
1,
],
'true string is ignored' => [
true,
'TRUE',
1,
],
'false string is ignored' => [
true,
'FALSE',
true,
],
'non-boolean string is ignored' => [
false,
'ABCD',
0,
],
[
true,
-2,
1,
],
[
false,
-2,
0,
],
];