PhpSpreadsheet/tests/data/Calculation/MathTrig
oleibman 346bad1b1d
Fix for Issue 2042 (SUM Partially Broken) (#2045)
As issue #2042 documents, SUM behaves differently with invalid strings depending on whether they come from a cell or are used as literals in the formula. SUM is not alone in this regard; COUNTA is another function within this behavior, and the solution to this one is modeled on COUNTA. New tests are added for SUM, and the resulting tests are duplicated to confirm correct behavior for both cells and literals.

Samples 16 (CSV), 17 (Html), and 21 (PDF) were adversely affected by this problem. 17 and 21 were immediately fixed, but 16 had another problem - Excel was not interpreting the UTF8 currency symbols correctly, even though the file was saved with a BOM. After some experimenting, it appears that the `sep=;` line generated by setExcelCompatibility(true) causes Excel to mis-handle the file. This seems like a bug - there is apparently no way to save a UTF-8 CSV with non-ASCII characters which specifies a non-standard separator which Excel will open correctly. I don't know if this is a recent change or if it is just the case that nobody noticed this problem till now. So, I changed Sample 16 to use setUseBom rather than setExcelCompatibility, which solved its problem. I then added new tests for setExcelCompatibility, with documentation of this problem.
2021-05-03 18:31:01 +02:00
..
ABS.php Continue MathTrig Breakup - Completion! (#1985) 2021-04-05 16:39:03 +02:00
ACOS.php Continue MathTrig Breakup - Trig Functions (#1905) 2021-03-13 12:06:30 +01:00
ACOSH.php Continue MathTrig Breakup - Trig Functions (#1905) 2021-03-13 12:06:30 +01:00
ACOT.php Continue MathTrig Breakup - Trig Functions (#1905) 2021-03-13 12:06:30 +01:00
ACOTH.php Continue MathTrig Breakup - Trig Functions (#1905) 2021-03-13 12:06:30 +01:00
ARABIC.php Update PHP-CS-Fixer rules 2020-05-18 13:49:57 +09:00
ASIN.php Continue MathTrig Breakup - Trig Functions (#1905) 2021-03-13 12:06:30 +01:00
ASINH.php Continue MathTrig Breakup - Trig Functions (#1905) 2021-03-13 12:06:30 +01:00
ATAN.php Continue MathTrig Breakup - Trig Functions (#1905) 2021-03-13 12:06:30 +01:00
ATAN2.php Continue MathTrig Breakup - Trig Functions (#1905) 2021-03-13 12:06:30 +01:00
ATANH.php Continue MathTrig Breakup - Trig Functions (#1905) 2021-03-13 12:06:30 +01:00
BASE.php Continue MathTrig Breakup - Problem Children (#1954) 2021-03-26 17:35:30 +09:00
CEILING.php ROUND Accepts null, false, and true as First Parameter (#1837) 2021-02-13 21:00:08 +01:00
CEILINGMATH.php ROUND Accepts null, false, and true as First Parameter (#1837) 2021-02-13 21:00:08 +01:00
CEILINGPRECISE.php ROUND Accepts null, false, and true as First Parameter (#1837) 2021-02-13 21:00:08 +01:00
COMBIN.php Continue MathTrig Breakup - Penultimate? (#1973) 2021-04-02 14:35:34 +02:00
COMBINA.php Continue MathTrig Breakup - Penultimate? (#1973) 2021-04-02 14:35:34 +02:00
COS.php Continue MathTrig Breakup - Trig Functions (#1905) 2021-03-13 12:06:30 +01:00
COSH.php Continue MathTrig Breakup - Trig Functions (#1905) 2021-03-13 12:06:30 +01:00
COT.php Continue MathTrig Breakup - Trig Functions (#1905) 2021-03-13 12:06:30 +01:00
COTH.php Continue MathTrig Breakup - Trig Functions (#1905) 2021-03-13 12:06:30 +01:00
CSC.php Continue MathTrig Breakup - Trig Functions (#1905) 2021-03-13 12:06:30 +01:00
CSCH.php Continue MathTrig Breakup - Trig Functions (#1905) 2021-03-13 12:06:30 +01:00
DEGREES.php Continue MathTrig Breakup - Completion! (#1985) 2021-04-05 16:39:03 +02:00
EVEN.php Continue MathTrig Breakup - Trig Functions (#1905) 2021-03-13 12:06:30 +01:00
EXP.php Continue MathTrig Breakup - Completion! (#1985) 2021-04-05 16:39:03 +02:00
FACT.php Continue MathTrig Breakup - Problem Children (#1954) 2021-03-26 17:35:30 +09:00
FACTDOUBLE.php Use proper syntax for variadic functions 2017-01-23 15:01:20 +09:00
FACTGNUMERIC.php Continue MathTrig Breakup - Problem Children (#1954) 2021-03-26 17:35:30 +09:00
FLOOR.php ROUND Accepts null, false, and true as First Parameter (#1837) 2021-02-13 21:00:08 +01:00
FLOORMATH.php ROUND Accepts null, false, and true as First Parameter (#1837) 2021-02-13 21:00:08 +01:00
FLOORPRECISE.php ROUND Accepts null, false, and true as First Parameter (#1837) 2021-02-13 21:00:08 +01:00
GCD.php Continue MathTrig Breakup - Penultimate? (#1973) 2021-04-02 14:35:34 +02:00
INT.php ROUND Accepts null, false, and true as First Parameter (#1837) 2021-02-13 21:00:08 +01:00
LCM.php Continue MathTrig Breakup - Penultimate? (#1973) 2021-04-02 14:35:34 +02:00
LN.php Continue MathTrig Breakup - Penultimate? (#1973) 2021-04-02 14:35:34 +02:00
LOG.php Continue MathTrig Breakup - Penultimate? (#1973) 2021-04-02 14:35:34 +02:00
LOG10.php Continue MathTrig Breakup - Penultimate? (#1973) 2021-04-02 14:35:34 +02:00
MDETERM.php Continue MathTrig Breakup - Penultimate? (#1973) 2021-04-02 14:35:34 +02:00
MINVERSE.php Continue MathTrig Breakup - Penultimate? (#1973) 2021-04-02 14:35:34 +02:00
MMULT.php Continue MathTrig Breakup - Problem Children (#1954) 2021-03-26 17:35:30 +09:00
MOD.php Continue MathTrig Breakup - Penultimate? (#1973) 2021-04-02 14:35:34 +02:00
MROUND.php ROUND Accepts null, false, and true as First Parameter (#1837) 2021-02-13 21:00:08 +01:00
MULTINOMIAL.php Continue MathTrig Breakup - Problem Children (#1954) 2021-03-26 17:35:30 +09:00
ODD.php Continue MathTrig Breakup - Trig Functions (#1905) 2021-03-13 12:06:30 +01:00
POWER.php Continue MathTrig Breakup - Penultimate? (#1973) 2021-04-02 14:35:34 +02:00
PRODUCT.php Continue MathTrig Breakup - Problem Children (#1954) 2021-03-26 17:35:30 +09:00
QUOTIENT.php Continue MathTrig Breakup - Problem Children (#1954) 2021-03-26 17:35:30 +09:00
RADIANS.php Continue MathTrig Breakup - Completion! (#1985) 2021-04-05 16:39:03 +02:00
RANDBETWEEN.php Continue MathTrig Breakup - Penultimate? (#1973) 2021-04-02 14:35:34 +02:00
ROMAN.php Support 'Forms' for ROMAN Function (#1828) 2021-02-13 21:23:58 +01:00
ROUND.php ROUND Accepts null, false, and true as First Parameter (#1837) 2021-02-13 21:00:08 +01:00
ROUNDDOWN.php ROUND Accepts null, false, and true as First Parameter (#1837) 2021-02-13 21:00:08 +01:00
ROUNDUP.php ROUND Accepts null, false, and true as First Parameter (#1837) 2021-02-13 21:00:08 +01:00
SEC.php Continue MathTrig Breakup - Trig Functions (#1905) 2021-03-13 12:06:30 +01:00
SECH.php Continue MathTrig Breakup - Trig Functions (#1905) 2021-03-13 12:06:30 +01:00
SERIESSUM.php Continue MathTrig Breakup - Problem Children (#1954) 2021-03-26 17:35:30 +09:00
SIGN.php Continue MathTrig Breakup - Trig Functions (#1905) 2021-03-13 12:06:30 +01:00
SIN.php Continue MathTrig Breakup - Trig Functions (#1905) 2021-03-13 12:06:30 +01:00
SINH.php Continue MathTrig Breakup - Trig Functions (#1905) 2021-03-13 12:06:30 +01:00
SQRT.php Continue MathTrig Breakup - Completion! (#1985) 2021-04-05 16:39:03 +02:00
SQRTPI.php Continue MathTrig Breakup - Completion! (#1985) 2021-04-05 16:39:03 +02:00
SUBTOTAL.php Continue MathTrig Breakup - Problem Children (#1954) 2021-03-26 17:35:30 +09:00
SUBTOTALHIDDEN.php Continue MathTrig Breakup - Problem Children (#1954) 2021-03-26 17:35:30 +09:00
SUM.php Fix for Issue 2042 (SUM Partially Broken) (#2045) 2021-05-03 18:31:01 +02:00
SUMIF.php Continue MathTrig Breakup - Problem Children (#1954) 2021-03-26 17:35:30 +09:00
SUMIFS.php Additional conditionals from math trig (#1885) 2021-02-28 10:24:33 +01:00
SUMLITERALS.php Fix for Issue 2042 (SUM Partially Broken) (#2045) 2021-05-03 18:31:01 +02:00
SUMPRODUCT.php Continue MathTrig Breakup - Problem Children (#1954) 2021-03-26 17:35:30 +09:00
SUMSQ.php Continue MathTrig Breakup - Completion! (#1985) 2021-04-05 16:39:03 +02:00
SUMX2MY2.php Continue MathTrig Breakup - Completion! (#1985) 2021-04-05 16:39:03 +02:00
SUMX2PY2.php Continue MathTrig Breakup - Completion! (#1985) 2021-04-05 16:39:03 +02:00
SUMXMY2.php Continue MathTrig Breakup - Completion! (#1985) 2021-04-05 16:39:03 +02:00
TAN.php Continue MathTrig Breakup - Trig Functions (#1905) 2021-03-13 12:06:30 +01:00
TANH.php Continue MathTrig Breakup - Trig Functions (#1905) 2021-03-13 12:06:30 +01:00
TRUNC.php ROUND Accepts null, false, and true as First Parameter (#1837) 2021-02-13 21:00:08 +01:00