2 Commits

Author SHA1 Message Date
saifulislamferoz 416cc52a94 Assert round-tripped values rather than Ods xml
Rewrite the test to write the spreadsheet, read it back and check
getValue() and getCalculatedValue(), following DurationTest, instead of
matching against the generated content.xml.
2026-08-15 15:28:08 +06:00
saifulislamferoz d3ae79dfaf Ods Writer: do not convert inside string literals
convertFormula() ran the cell reference, defined name and function name
conversions over the whole formula, so anything that looked like a reference
inside a quoted string was rewritten: ="THIS IS E1" was written out as
="THIS IS [.E1]". The comma to semicolon replacement had the same problem,
turning =IF(A1>1,"yes, really","no") into a formula whose text reads
"yes; really".

Split the formula on string literals and convert only the segments outside
of them. A range cannot be interrupted by a string literal, so every
reference still sees the context the conversion relies on.

Fixes #4454
2026-08-15 10:28:48 +06:00