Skip to content

Add unit tests for data bar conditional formatting defaults (#3015)#36

Merged
protobi-pieter merged 1 commit intomasterfrom
exceljs-3015
Jan 26, 2026
Merged

Add unit tests for data bar conditional formatting defaults (#3015)#36
protobi-pieter merged 1 commit intomasterfrom
exceljs-3015

Conversation

@protobi-pieter
Copy link
Copy Markdown

This PR adds unit tests for the data bar conditional formatting fix in PR #34.

Tests Added

  1. Unit test (spec/unit/xlsx/xform/sheet/cf-ext/databar-ext-xform.spec.js):

    • Tests that databar-ext-xform provides default cfvo array when not specified
    • Verifies rendering produces correct XML with min/max defaults
  2. Integration test (spec/integration/workbook-xlsx-writer/workbook-xlsx-writer.spec.js):

Test Results

All tests pass successfully (197 passing total, 2 pre-existing unrelated failures).

Related: exceljs#3015

Add tests to verify the fix for issue exceljs#3015 works correctly:
- Unit test: verifies databar-ext-xform renders default cfvo array when not specified
- Integration test: verifies end-to-end data bar creation with minimal options

Tests ensure data bars can be created with just type and priority,
without requiring manual specification of cfvo array or color.
@protobi-pieter protobi-pieter merged commit edb4926 into master Jan 26, 2026
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant