test for parsing strings, submitted by Werner Froidevaux

git-svn-id: https://svn.apache.org/repos/asf/jakarta/poi/trunk@352654 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Avik Sengupta 2002-05-28 12:41:17 +00:00
parent c8a2da3c1b
commit 3234ce48d5
1 changed files with 10 additions and 0 deletions

View File

@ -54,6 +54,16 @@ public class TestFormulaParser extends TestCase {
assertTrue("two tokens expected, got "+ptgs.length,ptgs.length == 2);
}
public void testFormulaWithString() {
Ptg[] ptgs;
FormulaParser fp;
fp = new FormulaParser("\"hello\" & \"world\" ;");
fp.parse();
ptgs = fp.getRPNPtg();
assertTrue("three token expected, got " + ptgs.length, ptgs.length == 3);
}
public static void main(String [] args) {
System.out.println("Testing org.apache.poi.hssf.record.formula.FormulaParser");
junit.textui.TestRunner.run(TestFormulaParser.class);