Stub the unit test which is the next thing to need to work for progress on #56737
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1611833 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
parent
551573dd95
commit
58d3cd3717
@ -19,13 +19,14 @@ package org.apache.poi.xssf.usermodel;
|
||||
|
||||
import junit.framework.TestCase;
|
||||
|
||||
import org.apache.poi.ss.formula.ptg.Ptg;
|
||||
import org.apache.poi.ss.formula.ptg.RefPtg;
|
||||
import org.apache.poi.ss.formula.ptg.IntPtg;
|
||||
import org.apache.poi.ss.formula.ptg.FuncPtg;
|
||||
import org.apache.poi.ss.formula.FormulaParseException;
|
||||
import org.apache.poi.ss.formula.FormulaParser;
|
||||
import org.apache.poi.ss.formula.FormulaType;
|
||||
import org.apache.poi.ss.formula.ptg.FuncPtg;
|
||||
import org.apache.poi.ss.formula.ptg.IntPtg;
|
||||
import org.apache.poi.ss.formula.ptg.Ptg;
|
||||
import org.apache.poi.ss.formula.ptg.RefPtg;
|
||||
import org.apache.poi.xssf.XSSFTestDataSamples;
|
||||
|
||||
public final class TestXSSFFormulaParser extends TestCase {
|
||||
|
||||
@ -88,4 +89,26 @@ public final class TestXSSFFormulaParser extends TestCase {
|
||||
assertTrue("", ptgs[0] instanceof IntPtg);
|
||||
assertTrue("", ptgs[1] instanceof FuncPtg);
|
||||
}
|
||||
|
||||
public void DISABLEDtestFormulaReferencesOtherWorkbook() {
|
||||
// Use a test file with the external linked table in place
|
||||
XSSFWorkbook wb = XSSFTestDataSamples.openSampleWorkbook("ref-56737.xlsx");
|
||||
XSSFEvaluationWorkbook fpb = XSSFEvaluationWorkbook.create(wb);
|
||||
Ptg[] ptgs;
|
||||
|
||||
// Reference to a single cell in a different workbook
|
||||
ptgs = parse(fpb, "[1]Uses!$A$1");
|
||||
assertEquals(1, ptgs.length);
|
||||
// TODO assert
|
||||
|
||||
// Reference to a sheet-scoped named range in a different workbook
|
||||
ptgs = parse(fpb, "[1]Defines!NR_To_A1");
|
||||
assertEquals(1, ptgs.length);
|
||||
// TODO assert
|
||||
|
||||
// Reference to a global named range in a different workbook
|
||||
ptgs = parse(fpb, "[1]!NR_Global_B2");
|
||||
assertEquals(1, ptgs.length);
|
||||
// TODO assert
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user