bug 57840: add disabled unit test with large number of structured reference formulas

patch and spreadsheet contributed by Mark Woolsey

git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1747878 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Javen O'Neal 2016-06-11 11:28:55 +00:00
parent 50f02c9a0f
commit 0e0afb3c72
2 changed files with 13 additions and 3 deletions

View File

@ -609,10 +609,20 @@ public final class TestXSSFFormulaEvaluation extends BaseTestFormulaEvaluator {
// bug 57721
@Test
public void structuredReferences() throws IOException {
XSSFWorkbook wb = XSSFTestDataSamples.openSampleWorkbook("evaluate_formula_with_structured_table_references.xlsx");
XSSFFormulaEvaluator.evaluateAllFormulaCells(wb);
verifyAllFormulasInWorkbookCanBeEvaluated("evaluate_formula_with_structured_table_references.xlsx");
}
// bug 57840
@Ignore("Takes over a minute to evaluate all formulas in this large workbook. Run this test when profiling for formula evaluation speed.")
@Test
public void testLotsOfFormulasWithStructuredReferencesToCalculatedTableColumns() throws IOException {
verifyAllFormulasInWorkbookCanBeEvaluated("StructuredRefs-lots-with-lookups.xlsx");
}
// FIXME: use junit4 parameterization
private static void verifyAllFormulasInWorkbookCanBeEvaluated(String sampleWorkbook) throws IOException {
XSSFWorkbook wb = XSSFTestDataSamples.openSampleWorkbook(sampleWorkbook);
XSSFFormulaEvaluator.evaluateAllFormulaCells(wb);
wb.close();
}