This is an automated email from the ASF dual-hosted git repository. jimjag pushed a commit to branch openformula in repository https://gitbox.apache.org/repos/asf/openoffice.git
commit 67dd4a87c05aaff90a33bb2db4fe09adc7386cc8 Author: Jim Jagielski <[email protected]> AuthorDate: Fri Nov 13 09:21:44 2026 -0500 test/odf-validate: add IFNA and COUNTBLANK cases on formula cells --- test/odf-validate/calcval-cases14.tsv | 4 ++++ test/odf-validate/calcval.py | 2 ++ 2 files changed, 6 insertions(+) diff --git a/test/odf-validate/calcval-cases14.tsv b/test/odf-validate/calcval-cases14.tsv index 6f9aa8a418..2683300e46 100644 --- a/test/odf-validate/calcval-cases14.tsv +++ b/test/odf-validate/calcval-cases14.tsv @@ -139,6 +139,9 @@ SKEWP.err =SKEWP(1/0) cell #ERR 6.x error value propagates IFNA.ref =IFNA(D1;10) cell 10 6.x cell reference containing a value (D1 = 10), returned unchanged IFNA.ref.text =IFNA(A1;10) cell s:y 6.x cell reference containing text (A1 = y), returned unchanged IFNA.range =IFNA(D1:D3;99) cell 10 6.x range reference, implicit intersection takes first cell (D1 = 10) +IFNA.ref.na =IFNA(AM1;99) cell 99 6.x cell reference containing #N/A (AM1 = NA()), fallback returned +IFNA.ref.err =IFNA(AM2;99) cell #ERR 6.x cell reference containing another error (AM2 = 1/0), error propagated +IFNA.ref.empty =IFNA(AM4;99) cell 0 6.x reference to an empty cell (AM4 unset) is not #N/A; the empty cell shows as 0 SKEWP.two =SKEWP(1;2) cell 0 6.x two observations, non-constant, zero skewness SKEW.text =SKEW(1;"text";2) cell - 6.3.7 a direct Text argument converts as in 6.3.5, implementation-defined (0 or an Error); AOO returns an Error SKEW.err =SKEW(1/0) cell #ERR 6.x regression: error argument propagates @@ -147,6 +150,7 @@ COUNTA.empty =COUNTA(D6:D7) cell 0 6.13.7 COUNTA: truly empty cells are not coun COUNTA.emptystr =COUNTA(1;"";"x") cell 3 6.13.7 COUNTA: empty string "" is non-blank and counted COUNTBLANK.range =COUNTBLANK(D1:D3) cell 0 6.13.8 COUNTBLANK over range with no empty cells COUNTBLANK.empty =COUNTBLANK(D6:D7) cell 2 6.13.8 COUNTBLANK: truly empty cells are counted (D6:D7 unset) +COUNTBLANK.emptystr =COUNTBLANK(AM3) cell 1 6.13.8 a cell whose formula returns "" (AM3): implementation-defined whether it is blank; AOO counts it DATE.pre1583 =DATE(1500;1;1) cell #ERR 6.10.2 DATE(1500;1;1) outside constraints (Year>=1904); impl-defined/diagnostic per ODF 1.4 — NOT mandatory #ERR. THIS CALCVAL ASSERTION IS AOO-SPECIFIC DIAGNOSTIC ONLY (observed #VALUE!), not an ODF conformance assertion. SYN-001-criteria =DCOUNT(R1:T6;;V1:V2) cell 4 6.x Criteria syntax §4.11.11 via DCOUNT against existing R1:T6 database and V1:V2 criteria fixtures (Age>=30 → B,C,D,E) BITAND.3params =BITAND(6;3;1) cell #ERR 6.6.2 BITAND exactly 2 params enforced diff --git a/test/odf-validate/calcval.py b/test/odf-validate/calcval.py index 9a16b5f906..319611a422 100644 --- a/test/odf-validate/calcval.py +++ b/test/odf-validate/calcval.py @@ -140,6 +140,8 @@ def setup_data(doc): put("AI1", [[v] for v in (1, 3, 5)]) put("AJ1", [[v] for v in (2, 4, 7, 9)]) put("AK1", [[v] for v in (2, 4, 7, 9)]) + for addr, f in (("AM1", "=NA()"), ("AM2", "=1/0"), ("AM3", '=""')): + sh.getCellRangeByName(addr).setFormula(f) return sh
