poi-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From one...@apache.org
Subject svn commit: r1751240 [2/3] - in /poi/trunk/src: examples/src/org/apache/poi/hssf/usermodel/examples/ examples/src/org/apache/poi/hssf/view/ examples/src/org/apache/poi/ss/examples/ java/org/apache/poi/hssf/record/ java/org/apache/poi/hssf/usermodel/ ja...
Date Mon, 04 Jul 2016 10:15:19 GMT
Modified: poi/trunk/src/ooxml/testcases/org/apache/poi/xssf/usermodel/TestXSSFSheet.java
URL: http://svn.apache.org/viewvc/poi/trunk/src/ooxml/testcases/org/apache/poi/xssf/usermodel/TestXSSFSheet.java?rev=1751240&r1=1751239&r2=1751240&view=diff
==============================================================================
--- poi/trunk/src/ooxml/testcases/org/apache/poi/xssf/usermodel/TestXSSFSheet.java (original)
+++ poi/trunk/src/ooxml/testcases/org/apache/poi/xssf/usermodel/TestXSSFSheet.java Mon Jul  4 10:15:18 2016
@@ -45,6 +45,7 @@ import org.apache.poi.ss.usermodel.AutoF
 import org.apache.poi.ss.usermodel.BaseTestXSheet;
 import org.apache.poi.ss.usermodel.Cell;
 import org.apache.poi.ss.usermodel.CellCopyPolicy;
+import org.apache.poi.ss.usermodel.CellType;
 import org.apache.poi.ss.usermodel.ClientAnchor;
 import org.apache.poi.ss.usermodel.FormulaError;
 import org.apache.poi.ss.usermodel.IgnoredErrorType;
@@ -1483,44 +1484,44 @@ public final class TestXSSFSheet extends
 
         // Blank
         cell = CellUtil.getCell(destRow, col++);
-        assertEquals("[Blank] C7 cell type", Cell.CELL_TYPE_BLANK, cell.getCellType());
+        assertEquals("[Blank] C7 cell type", CellType.BLANK, cell.getCellType());
 
         // Error
         cell = CellUtil.getCell(destRow, col++);
-        assertEquals("[Error] D7 cell type", Cell.CELL_TYPE_ERROR, cell.getCellType());
+        assertEquals("[Error] D7 cell type", CellType.ERROR, cell.getCellType());
         final FormulaError error = FormulaError.forInt(cell.getErrorCellValue());
         assertEquals("[Error] D7 cell value", FormulaError.NA, error); //FIXME: XSSFCell and HSSFCell expose different interfaces. getErrorCellString would be helpful here
 
         // Date
         cell = CellUtil.getCell(destRow, col++);
-        assertEquals("[Date] E7 cell type", Cell.CELL_TYPE_NUMERIC, cell.getCellType());
+        assertEquals("[Date] E7 cell type", CellType.NUMERIC, cell.getCellType());
         final Date date = LocaleUtil.getLocaleCalendar(2000, Calendar.JANUARY, 1).getTime();
         assertEquals("[Date] E7 cell value", date, cell.getDateCellValue());
 
         // Boolean
         cell = CellUtil.getCell(destRow, col++);
-        assertEquals("[Boolean] F7 cell type", Cell.CELL_TYPE_BOOLEAN, cell.getCellType());
+        assertEquals("[Boolean] F7 cell type", CellType.BOOLEAN, cell.getCellType());
         assertEquals("[Boolean] F7 cell value", true, cell.getBooleanCellValue());
 
         // String
         cell = CellUtil.getCell(destRow, col++);
-        assertEquals("[String] G7 cell type", Cell.CELL_TYPE_STRING, cell.getCellType());
+        assertEquals("[String] G7 cell type", CellType.STRING, cell.getCellType());
         assertEquals("[String] G7 cell value", "Hello", cell.getStringCellValue());
         
         // Int
         cell = CellUtil.getCell(destRow, col++);
-        assertEquals("[Int] H7 cell type", Cell.CELL_TYPE_NUMERIC, cell.getCellType());
+        assertEquals("[Int] H7 cell type", CellType.NUMERIC, cell.getCellType());
         assertEquals("[Int] H7 cell value", 15, (int) cell.getNumericCellValue());
         
         // Float
         cell = CellUtil.getCell(destRow, col++);
-        assertEquals("[Float] I7 cell type", Cell.CELL_TYPE_NUMERIC, cell.getCellType());
+        assertEquals("[Float] I7 cell type", CellType.NUMERIC, cell.getCellType());
         assertEquals("[Float] I7 cell value", 12.5, cell.getNumericCellValue(), FLOAT_PRECISION);
         
         // Cell Formula
         cell = CellUtil.getCell(destRow, col++);
         assertEquals("J7", new CellReference(cell).formatAsString());
-        assertEquals("[Cell Formula] J7 cell type", Cell.CELL_TYPE_FORMULA, cell.getCellType());
+        assertEquals("[Cell Formula] J7 cell type", CellType.FORMULA, cell.getCellType());
         assertEquals("[Cell Formula] J7 cell formula", "5+2", cell.getCellFormula());
         System.out.println("Cell formula evaluation currently unsupported");
         
@@ -1529,21 +1530,21 @@ public final class TestXSSFSheet extends
         cell = CellUtil.getCell(destRow, col++);
         assertEquals("K7", new CellReference(cell).formatAsString());
         assertEquals("[Cell Formula with Reference] K7 cell type",
-                Cell.CELL_TYPE_FORMULA, cell.getCellType());
+                CellType.FORMULA, cell.getCellType());
         assertEquals("[Cell Formula with Reference] K7 cell formula",
                 "J7+H$2", cell.getCellFormula());
         
         // Cell Formula with Reference spanning multiple rows
         cell = CellUtil.getCell(destRow, col++);
         assertEquals("[Cell Formula with Reference spanning multiple rows] L7 cell type",
-                Cell.CELL_TYPE_FORMULA, cell.getCellType());
+                CellType.FORMULA, cell.getCellType());
         assertEquals("[Cell Formula with Reference spanning multiple rows] L7 cell formula",
                 "G7&\" \"&G8", cell.getCellFormula());
         
         // Cell Formula with Reference spanning multiple rows
         cell = CellUtil.getCell(destRow, col++);
         assertEquals("[Cell Formula with Area Reference] M7 cell type",
-                Cell.CELL_TYPE_FORMULA, cell.getCellType());
+                CellType.FORMULA, cell.getCellType());
         assertEquals("[Cell Formula with Area Reference] M7 cell formula",
                 "SUM(H7:I8)", cell.getCellFormula());
         
@@ -1552,13 +1553,13 @@ public final class TestXSSFSheet extends
         System.out.println("Array formulas currently unsupported");
         // FIXME: Array Formula set with Sheet.setArrayFormula() instead of cell.setFormula()
         /*
-        assertEquals("[Array Formula] N7 cell type", Cell.CELL_TYPE_FORMULA, cell.getCellType());
+        assertEquals("[Array Formula] N7 cell type", CellType.FORMULA, cell.getCellType());
         assertEquals("[Array Formula] N7 cell formula", "{SUM(H7:J7*{1,2,3})}", cell.getCellFormula());
         */
         
         // Data Format
         cell = CellUtil.getCell(destRow, col++);
-        assertEquals("[Data Format] O7 cell type;", Cell.CELL_TYPE_NUMERIC, cell.getCellType());
+        assertEquals("[Data Format] O7 cell type;", CellType.NUMERIC, cell.getCellType());
         assertEquals("[Data Format] O7 cell value", 100.20, cell.getNumericCellValue(), FLOAT_PRECISION);
         //FIXME: currently fails
         final String moneyFormat = "\"$\"#,##0.00_);[Red]\\(\"$\"#,##0.00\\)";
@@ -1637,83 +1638,83 @@ public final class TestXSSFSheet extends
         // Blank
         col++;
         cell = CellUtil.getCell(destRow1, col);
-        assertEquals("[Blank] C10 cell type", Cell.CELL_TYPE_BLANK, cell.getCellType());
+        assertEquals("[Blank] C10 cell type", CellType.BLANK, cell.getCellType());
         
         cell = CellUtil.getCell(destRow2, col);
-        assertEquals("[Blank] C11 cell type", Cell.CELL_TYPE_BLANK, cell.getCellType());
+        assertEquals("[Blank] C11 cell type", CellType.BLANK, cell.getCellType());
         
         // Error
         col++;
         cell = CellUtil.getCell(destRow1, col);
-        assertEquals("[Error] D10 cell type", Cell.CELL_TYPE_ERROR, cell.getCellType());
+        assertEquals("[Error] D10 cell type", CellType.ERROR, cell.getCellType());
         FormulaError error = FormulaError.forInt(cell.getErrorCellValue());
         assertEquals("[Error] D10 cell value", FormulaError.NA, error); //FIXME: XSSFCell and HSSFCell expose different interfaces. getErrorCellString would be helpful here
         
         cell = CellUtil.getCell(destRow2, col);
-        assertEquals("[Error] D11 cell type", Cell.CELL_TYPE_ERROR, cell.getCellType());
+        assertEquals("[Error] D11 cell type", CellType.ERROR, cell.getCellType());
         error = FormulaError.forInt(cell.getErrorCellValue());
         assertEquals("[Error] D11 cell value", FormulaError.NAME, error); //FIXME: XSSFCell and HSSFCell expose different interfaces. getErrorCellString would be helpful here
         
         // Date
         col++;
         cell = CellUtil.getCell(destRow1, col);
-        assertEquals("[Date] E10 cell type", Cell.CELL_TYPE_NUMERIC, cell.getCellType());
+        assertEquals("[Date] E10 cell type", CellType.NUMERIC, cell.getCellType());
         Date date = LocaleUtil.getLocaleCalendar(2000, Calendar.JANUARY, 1).getTime();
         assertEquals("[Date] E10 cell value", date, cell.getDateCellValue());
         
         cell = CellUtil.getCell(destRow2, col);
-        assertEquals("[Date] E11 cell type", Cell.CELL_TYPE_NUMERIC, cell.getCellType());
+        assertEquals("[Date] E11 cell type", CellType.NUMERIC, cell.getCellType());
         date = LocaleUtil.getLocaleCalendar(2000, Calendar.JANUARY, 2).getTime();
         assertEquals("[Date] E11 cell value", date, cell.getDateCellValue());
         
         // Boolean
         col++;
         cell = CellUtil.getCell(destRow1, col);
-        assertEquals("[Boolean] F10 cell type", Cell.CELL_TYPE_BOOLEAN, cell.getCellType());
+        assertEquals("[Boolean] F10 cell type", CellType.BOOLEAN, cell.getCellType());
         assertEquals("[Boolean] F10 cell value", true, cell.getBooleanCellValue());
         
         cell = CellUtil.getCell(destRow2, col);
-        assertEquals("[Boolean] F11 cell type", Cell.CELL_TYPE_BOOLEAN, cell.getCellType());
+        assertEquals("[Boolean] F11 cell type", CellType.BOOLEAN, cell.getCellType());
         assertEquals("[Boolean] F11 cell value", false, cell.getBooleanCellValue());
         
         // String
         col++;
         cell = CellUtil.getCell(destRow1, col);
-        assertEquals("[String] G10 cell type", Cell.CELL_TYPE_STRING, cell.getCellType());
+        assertEquals("[String] G10 cell type", CellType.STRING, cell.getCellType());
         assertEquals("[String] G10 cell value", "Hello", cell.getStringCellValue());
         
         cell = CellUtil.getCell(destRow2, col);
-        assertEquals("[String] G11 cell type", Cell.CELL_TYPE_STRING, cell.getCellType());
+        assertEquals("[String] G11 cell type", CellType.STRING, cell.getCellType());
         assertEquals("[String] G11 cell value", "World", cell.getStringCellValue());
         
         // Int
         col++;
         cell = CellUtil.getCell(destRow1, col);
-        assertEquals("[Int] H10 cell type", Cell.CELL_TYPE_NUMERIC, cell.getCellType());
+        assertEquals("[Int] H10 cell type", CellType.NUMERIC, cell.getCellType());
         assertEquals("[Int] H10 cell value", 15, (int) cell.getNumericCellValue());
         
         cell = CellUtil.getCell(destRow2, col);
-        assertEquals("[Int] H11 cell type", Cell.CELL_TYPE_NUMERIC, cell.getCellType());
+        assertEquals("[Int] H11 cell type", CellType.NUMERIC, cell.getCellType());
         assertEquals("[Int] H11 cell value", 42, (int) cell.getNumericCellValue());
         
         // Float
         col++;
         cell = CellUtil.getCell(destRow1, col);
-        assertEquals("[Float] I10 cell type", Cell.CELL_TYPE_NUMERIC, cell.getCellType());
+        assertEquals("[Float] I10 cell type", CellType.NUMERIC, cell.getCellType());
         assertEquals("[Float] I10 cell value", 12.5, cell.getNumericCellValue(), FLOAT_PRECISION);
         
         cell = CellUtil.getCell(destRow2, col);
-        assertEquals("[Float] I11 cell type", Cell.CELL_TYPE_NUMERIC, cell.getCellType());
+        assertEquals("[Float] I11 cell type", CellType.NUMERIC, cell.getCellType());
         assertEquals("[Float] I11 cell value", 5.5, cell.getNumericCellValue(), FLOAT_PRECISION);
         
         // Cell Formula
         col++;
         cell = CellUtil.getCell(destRow1, col);
-        assertEquals("[Cell Formula] J10 cell type", Cell.CELL_TYPE_FORMULA, cell.getCellType());
+        assertEquals("[Cell Formula] J10 cell type", CellType.FORMULA, cell.getCellType());
         assertEquals("[Cell Formula] J10 cell formula", "5+2", cell.getCellFormula());
         
         cell = CellUtil.getCell(destRow2, col);
-        assertEquals("[Cell Formula] J11 cell type", Cell.CELL_TYPE_FORMULA, cell.getCellType());
+        assertEquals("[Cell Formula] J11 cell type", CellType.FORMULA, cell.getCellType());
         assertEquals("[Cell Formula] J11 cell formula", "6+18", cell.getCellFormula());
 
         // Cell Formula with Reference
@@ -1721,25 +1722,25 @@ public final class TestXSSFSheet extends
         // Formula row references should be adjusted by destRowNum-srcRowNum
         cell = CellUtil.getCell(destRow1, col);
         assertEquals("[Cell Formula with Reference] K10 cell type",
-                Cell.CELL_TYPE_FORMULA, cell.getCellType());
+                CellType.FORMULA, cell.getCellType());
         assertEquals("[Cell Formula with Reference] K10 cell formula",
                 "J10+H$2", cell.getCellFormula());
         
         cell = CellUtil.getCell(destRow2, col);
-        assertEquals("[Cell Formula with Reference] K11 cell type", Cell.CELL_TYPE_FORMULA, cell.getCellType());
+        assertEquals("[Cell Formula with Reference] K11 cell type", CellType.FORMULA, cell.getCellType());
         assertEquals("[Cell Formula with Reference] K11 cell formula", "J11+H$2", cell.getCellFormula());
         
         // Cell Formula with Reference spanning multiple rows
         col++;
         cell = CellUtil.getCell(destRow1, col);
         assertEquals("[Cell Formula with Reference spanning multiple rows] L10 cell type",
-                Cell.CELL_TYPE_FORMULA, cell.getCellType());
+                CellType.FORMULA, cell.getCellType());
         assertEquals("[Cell Formula with Reference spanning multiple rows] L10 cell formula",
                 "G10&\" \"&G11", cell.getCellFormula());
         
         cell = CellUtil.getCell(destRow2, col);
         assertEquals("[Cell Formula with Reference spanning multiple rows] L11 cell type",
-                Cell.CELL_TYPE_FORMULA, cell.getCellType());
+                CellType.FORMULA, cell.getCellType());
         assertEquals("[Cell Formula with Reference spanning multiple rows] L11 cell formula",
                 "G11&\" \"&G12", cell.getCellFormula());
         
@@ -1747,13 +1748,13 @@ public final class TestXSSFSheet extends
         col++;
         cell = CellUtil.getCell(destRow1, col);
         assertEquals("[Cell Formula with Area Reference] M10 cell type",
-                Cell.CELL_TYPE_FORMULA, cell.getCellType());
+                CellType.FORMULA, cell.getCellType());
         assertEquals("[Cell Formula with Area Reference] M10 cell formula",
                 "SUM(H10:I11)", cell.getCellFormula());
         
         cell = CellUtil.getCell(destRow2, col);
         assertEquals("[Cell Formula with Area Reference] M11 cell type",
-                Cell.CELL_TYPE_FORMULA, cell.getCellType());
+                CellType.FORMULA, cell.getCellType());
         assertEquals("[Cell Formula with Area Reference] M11 cell formula",
                 "SUM($H$3:I10)", cell.getCellFormula()); //Also acceptable: SUM($H10:I$3), but this AreaReference isn't in ascending order
         
@@ -1763,19 +1764,19 @@ public final class TestXSSFSheet extends
         // System.out.println("Array formulas currently unsupported");
     /*
         // FIXME: Array Formula set with Sheet.setArrayFormula() instead of cell.setFormula()
-        assertEquals("[Array Formula] N10 cell type", Cell.CELL_TYPE_FORMULA, cell.getCellType());
+        assertEquals("[Array Formula] N10 cell type", CellType.FORMULA, cell.getCellType());
         assertEquals("[Array Formula] N10 cell formula", "{SUM(H10:J10*{1,2,3})}", cell.getCellFormula());
         
         cell = CellUtil.getCell(destRow2, col);
         // FIXME: Array Formula set with Sheet.setArrayFormula() instead of cell.setFormula() 
-        assertEquals("[Array Formula] N11 cell type", Cell.CELL_TYPE_FORMULA, cell.getCellType());
+        assertEquals("[Array Formula] N11 cell type", CellType.FORMULA, cell.getCellType());
         assertEquals("[Array Formula] N11 cell formula", "{SUM(H11:J11*{1,2,3})}", cell.getCellFormula());
      */
         
         // Data Format
         col++;
         cell = CellUtil.getCell(destRow2, col);
-        assertEquals("[Data Format] O10 cell type", Cell.CELL_TYPE_NUMERIC, cell.getCellType());
+        assertEquals("[Data Format] O10 cell type", CellType.NUMERIC, cell.getCellType());
         assertEquals("[Data Format] O10 cell value", 100.20, cell.getNumericCellValue(), FLOAT_PRECISION);
         final String moneyFormat = "\"$\"#,##0.00_);[Red]\\(\"$\"#,##0.00\\)";
         assertEquals("[Data Format] O10 cell data format", moneyFormat, cell.getCellStyle().getDataFormatString());

Modified: poi/trunk/src/ooxml/testcases/org/apache/poi/xssf/usermodel/TestXSSFSheetShiftRows.java
URL: http://svn.apache.org/viewvc/poi/trunk/src/ooxml/testcases/org/apache/poi/xssf/usermodel/TestXSSFSheetShiftRows.java?rev=1751240&r1=1751239&r2=1751240&view=diff
==============================================================================
--- poi/trunk/src/ooxml/testcases/org/apache/poi/xssf/usermodel/TestXSSFSheetShiftRows.java (original)
+++ poi/trunk/src/ooxml/testcases/org/apache/poi/xssf/usermodel/TestXSSFSheetShiftRows.java Mon Jul  4 10:15:18 2016
@@ -26,6 +26,7 @@ import java.io.IOException;
 
 import org.apache.poi.ss.usermodel.BaseTestSheetShiftRows;
 import org.apache.poi.ss.usermodel.Cell;
+import org.apache.poi.ss.usermodel.CellType;
 import org.apache.poi.ss.usermodel.Comment;
 import org.apache.poi.ss.usermodel.Row;
 import org.apache.poi.ss.usermodel.Sheet;
@@ -116,7 +117,7 @@ public final class TestXSSFSheetShiftRow
             return;
         }
         Cell readCell = readRow.getCell(0);
-        if(readCell.getCellType() == Cell.CELL_TYPE_NUMERIC) {
+        if(readCell.getCellType() == CellType.NUMERIC) {
             assertEquals(expect, Double.toString(readCell.getNumericCellValue()));
         } else {
             assertEquals(expect, readCell.getStringCellValue());

Modified: poi/trunk/src/scratchpad/src/org/apache/poi/hwpf/QuickTest.java
URL: http://svn.apache.org/viewvc/poi/trunk/src/scratchpad/src/org/apache/poi/hwpf/QuickTest.java?rev=1751240&r1=1751239&r2=1751240&view=diff
==============================================================================
--- poi/trunk/src/scratchpad/src/org/apache/poi/hwpf/QuickTest.java (original)
+++ poi/trunk/src/scratchpad/src/org/apache/poi/hwpf/QuickTest.java Mon Jul  4 10:15:18 2016
@@ -18,7 +18,6 @@
 package org.apache.poi.hwpf;
 
 import java.io.FileInputStream;
-import java.io.FileNotFoundException;
 import java.io.IOException;
 
 import org.apache.poi.hwpf.usermodel.CharacterRun;

Modified: poi/trunk/src/testcases/org/apache/poi/hssf/model/TestFormulaParserEval.java
URL: http://svn.apache.org/viewvc/poi/trunk/src/testcases/org/apache/poi/hssf/model/TestFormulaParserEval.java?rev=1751240&r1=1751239&r2=1751240&view=diff
==============================================================================
--- poi/trunk/src/testcases/org/apache/poi/hssf/model/TestFormulaParserEval.java (original)
+++ poi/trunk/src/testcases/org/apache/poi/hssf/model/TestFormulaParserEval.java Mon Jul  4 10:15:18 2016
@@ -30,6 +30,7 @@ import org.apache.poi.hssf.usermodel.HSS
 import org.apache.poi.hssf.usermodel.HSSFSheet;
 import org.apache.poi.hssf.usermodel.HSSFWorkbook;
 import org.apache.poi.ss.formula.FormulaParseException;
+import org.apache.poi.ss.usermodel.CellType;
 import org.apache.poi.ss.usermodel.CellValue;
 
 /**
@@ -98,7 +99,7 @@ public final class TestFormulaParserEval
 			}
 			throw e;
 		}
-		assertEquals(HSSFCell.CELL_TYPE_NUMERIC, result.getCellType());
+		assertEquals(CellType.NUMERIC, result.getCellType());
 		assertEquals(42.0, result.getNumberValue(), 0.0);
 	}
 }

Modified: poi/trunk/src/testcases/org/apache/poi/hssf/model/TestRVA.java
URL: http://svn.apache.org/viewvc/poi/trunk/src/testcases/org/apache/poi/hssf/model/TestRVA.java?rev=1751240&r1=1751239&r2=1751240&view=diff
==============================================================================
--- poi/trunk/src/testcases/org/apache/poi/hssf/model/TestRVA.java (original)
+++ poi/trunk/src/testcases/org/apache/poi/hssf/model/TestRVA.java Mon Jul  4 10:15:18 2016
@@ -33,6 +33,7 @@ import org.apache.poi.hssf.usermodel.HSS
 import org.apache.poi.poifs.filesystem.NPOIFSFileSystem;
 import org.apache.poi.ss.formula.ptg.AttrPtg;
 import org.apache.poi.ss.formula.ptg.Ptg;
+import org.apache.poi.ss.usermodel.CellType;
 import org.junit.AfterClass;
 import org.junit.Test;
 import org.junit.runner.RunWith;
@@ -79,7 +80,7 @@ public final class TestRVA {
                 break;
             }
             HSSFCell cell = row.getCell(0);
-            if (cell == null || cell.getCellType() == HSSFCell.CELL_TYPE_BLANK) {
+            if (cell == null || cell.getCellType() == CellType.BLANK) {
                 break;
             }
 

Modified: poi/trunk/src/testcases/org/apache/poi/hssf/record/TestSharedFormulaRecord.java
URL: http://svn.apache.org/viewvc/poi/trunk/src/testcases/org/apache/poi/hssf/record/TestSharedFormulaRecord.java?rev=1751240&r1=1751239&r2=1751240&view=diff
==============================================================================
--- poi/trunk/src/testcases/org/apache/poi/hssf/record/TestSharedFormulaRecord.java (original)
+++ poi/trunk/src/testcases/org/apache/poi/hssf/record/TestSharedFormulaRecord.java Mon Jul  4 10:15:18 2016
@@ -26,6 +26,7 @@ import org.apache.poi.ss.formula.ptg.Ptg
 import org.apache.poi.ss.formula.ptg.RefPtg;
 import org.apache.poi.ss.formula.SharedFormula;
 import org.apache.poi.hssf.usermodel.*;
+import org.apache.poi.ss.usermodel.CellType;
 import org.apache.poi.ss.usermodel.CellValue;
 import org.apache.poi.ss.formula.FormulaParser;
 import org.apache.poi.ss.formula.FormulaRenderer;
@@ -203,7 +204,7 @@ public final class TestSharedFormulaReco
 
         assertEquals("A$1*2", sheet.getRow(ROW_IX).getCell(1).getCellFormula());
         cell = sheet.getRow(ROW_IX).getCell(1);
-        cell.setCellType(HSSFCell.CELL_TYPE_BLANK);
+        cell.setCellType(CellType.BLANK);
         assertEquals(3, countSharedFormulas(sheet));
 
         wb = HSSFTestDataSamples.writeOutAndReadBack(wb);
@@ -227,7 +228,7 @@ public final class TestSharedFormulaReco
     private static void confirmCellEvaluation(HSSFWorkbook wb, HSSFCell cell, double expectedValue) {
         HSSFFormulaEvaluator fe = new HSSFFormulaEvaluator(wb);
         CellValue cv = fe.evaluate(cell);
-        assertEquals(HSSFCell.CELL_TYPE_NUMERIC, cv.getCellType());
+        assertEquals(CellType.NUMERIC, cv.getCellType());
         assertEquals(expectedValue, cv.getNumberValue(), 0.0);
     }
 

Modified: poi/trunk/src/testcases/org/apache/poi/hssf/usermodel/TestBug42464.java
URL: http://svn.apache.org/viewvc/poi/trunk/src/testcases/org/apache/poi/hssf/usermodel/TestBug42464.java?rev=1751240&r1=1751239&r2=1751240&view=diff
==============================================================================
--- poi/trunk/src/testcases/org/apache/poi/hssf/usermodel/TestBug42464.java (original)
+++ poi/trunk/src/testcases/org/apache/poi/hssf/usermodel/TestBug42464.java Mon Jul  4 10:15:18 2016
@@ -27,6 +27,7 @@ import org.apache.poi.hssf.record.aggreg
 import org.apache.poi.hssf.util.CellReference;
 import org.apache.poi.ss.formula.ptg.Ptg;
 import org.apache.poi.ss.usermodel.Cell;
+import org.apache.poi.ss.usermodel.CellType;
 import org.apache.poi.ss.usermodel.CellValue;
 import org.apache.poi.ss.usermodel.Row;
 import org.junit.Test;
@@ -67,7 +68,7 @@ public final class TestBug42464 {
 		Iterator<Cell> it = row.cellIterator();
 		while(it.hasNext()) {
 			HSSFCell cell = (HSSFCell)it.next();
-			if(cell.getCellType() != HSSFCell.CELL_TYPE_FORMULA) {
+			if(cell.getCellType() != CellType.FORMULA) {
 			    continue;
 			}
 			FormulaRecordAggregate record = (FormulaRecordAggregate) cell.getCellValueRecord();

Modified: poi/trunk/src/testcases/org/apache/poi/hssf/usermodel/TestCellStyle.java
URL: http://svn.apache.org/viewvc/poi/trunk/src/testcases/org/apache/poi/hssf/usermodel/TestCellStyle.java?rev=1751240&r1=1751239&r2=1751240&view=diff
==============================================================================
--- poi/trunk/src/testcases/org/apache/poi/hssf/usermodel/TestCellStyle.java (original)
+++ poi/trunk/src/testcases/org/apache/poi/hssf/usermodel/TestCellStyle.java Mon Jul  4 10:15:18 2016
@@ -27,6 +27,7 @@ import org.apache.poi.hssf.HSSFTestDataS
 import org.apache.poi.ss.usermodel.BorderStyle;
 import org.apache.poi.ss.usermodel.Cell;
 import org.apache.poi.ss.usermodel.CellStyle;
+import org.apache.poi.ss.usermodel.CellType;
 import org.apache.poi.ss.usermodel.Font;
 import org.apache.poi.ss.usermodel.Row;
 import org.apache.poi.ss.usermodel.Sheet;
@@ -435,7 +436,7 @@ public final class TestCellStyle extends
         
                             Cell cell = row.getCell(idxCell);
                             cell.getCellStyle().getDataFormatString();
-                            if (cell.getCellType() == HSSFCell.CELL_TYPE_NUMERIC) {
+                            if (cell.getCellType() == CellType.NUMERIC) {
                                 boolean isDate = HSSFDateUtil.isCellDateFormatted(cell);
                                 if (idxCell > 0 && isDate) {
                                     fail("cell " + idxCell + " is not a date: " + idxCell.toString());

Modified: poi/trunk/src/testcases/org/apache/poi/hssf/usermodel/TestExternalReferenceChange.java
URL: http://svn.apache.org/viewvc/poi/trunk/src/testcases/org/apache/poi/hssf/usermodel/TestExternalReferenceChange.java?rev=1751240&r1=1751239&r2=1751240&view=diff
==============================================================================
--- poi/trunk/src/testcases/org/apache/poi/hssf/usermodel/TestExternalReferenceChange.java (original)
+++ poi/trunk/src/testcases/org/apache/poi/hssf/usermodel/TestExternalReferenceChange.java Mon Jul  4 10:15:18 2016
@@ -19,7 +19,7 @@ package org.apache.poi.hssf.usermodel;
 import java.io.IOException;
 
 import org.apache.poi.hssf.HSSFTestDataSamples;
-import org.apache.poi.ss.usermodel.Cell;
+import org.apache.poi.ss.usermodel.CellType;
 
 import junit.framework.TestCase;
 
@@ -51,7 +51,7 @@ public class TestExternalReferenceChange
 		HSSFSheet lSheet = mainWorkbook.getSheetAt(0);
 		HSSFCell lA1Cell = lSheet.getRow(0).getCell(0);
 		
-		assertEquals(Cell.CELL_TYPE_FORMULA, lA1Cell.getCellType());
+		assertEquals(CellType.FORMULA, lA1Cell.getCellType());
 		
 		HSSFFormulaEvaluator lMainWorkbookEvaluator = new HSSFFormulaEvaluator(mainWorkbook);
 		HSSFFormulaEvaluator lSourceEvaluator = new HSSFFormulaEvaluator(sourceWorkbook);
@@ -59,7 +59,7 @@ public class TestExternalReferenceChange
 				new String[]{MAIN_WORKBOOK_FILENAME, SOURCE_WORKBOOK_FILENAME}, 
 				new HSSFFormulaEvaluator[] {lMainWorkbookEvaluator, lSourceEvaluator});
 		
-		assertEquals(Cell.CELL_TYPE_NUMERIC, lMainWorkbookEvaluator.evaluateFormulaCell(lA1Cell));
+		assertEquals(CellType.NUMERIC, lMainWorkbookEvaluator.evaluateFormulaCell(lA1Cell));
 
 		assertEquals(20.0d, lA1Cell.getNumericCellValue(), 0.00001d);
 

Modified: poi/trunk/src/testcases/org/apache/poi/hssf/usermodel/TestFormulaEvaluatorBugs.java
URL: http://svn.apache.org/viewvc/poi/trunk/src/testcases/org/apache/poi/hssf/usermodel/TestFormulaEvaluatorBugs.java?rev=1751240&r1=1751239&r2=1751240&view=diff
==============================================================================
--- poi/trunk/src/testcases/org/apache/poi/hssf/usermodel/TestFormulaEvaluatorBugs.java (original)
+++ poi/trunk/src/testcases/org/apache/poi/hssf/usermodel/TestFormulaEvaluatorBugs.java Mon Jul  4 10:15:18 2016
@@ -40,6 +40,7 @@ import org.apache.poi.ss.formula.ptg.Fun
 import org.apache.poi.ss.formula.ptg.Ptg;
 import org.apache.poi.ss.formula.ptg.RefPtg;
 import org.apache.poi.ss.usermodel.Cell;
+import org.apache.poi.ss.usermodel.CellType;
 import org.apache.poi.ss.usermodel.Row;
 import org.apache.poi.ss.util.CellReference;
 import org.apache.poi.util.LocaleUtil;
@@ -565,7 +566,7 @@ public final class TestFormulaEvaluatorB
         }
     }
     private Ptg[] getPtgs(HSSFCell cell) {
-        assertEquals(HSSFCell.CELL_TYPE_FORMULA, cell.getCellType());
+        assertEquals(CellType.FORMULA, cell.getCellType());
         assertEquals(FormulaRecordAggregate.class, cell.getCellValueRecord().getClass());
         FormulaRecordAggregate agg = (FormulaRecordAggregate)cell.getCellValueRecord();
         FormulaRecord rec = agg.getFormulaRecord();

Modified: poi/trunk/src/testcases/org/apache/poi/hssf/usermodel/TestFormulaEvaluatorDocs.java
URL: http://svn.apache.org/viewvc/poi/trunk/src/testcases/org/apache/poi/hssf/usermodel/TestFormulaEvaluatorDocs.java?rev=1751240&r1=1751239&r2=1751240&view=diff
==============================================================================
--- poi/trunk/src/testcases/org/apache/poi/hssf/usermodel/TestFormulaEvaluatorDocs.java (original)
+++ poi/trunk/src/testcases/org/apache/poi/hssf/usermodel/TestFormulaEvaluatorDocs.java Mon Jul  4 10:15:18 2016
@@ -19,6 +19,8 @@ package org.apache.poi.hssf.usermodel;
 
 import java.util.Iterator;
 
+import org.apache.poi.ss.usermodel.CellType;
+
 import junit.framework.TestCase;
 
 /**
@@ -75,11 +77,11 @@ public final class TestFormulaEvaluatorD
 
 				for(Iterator cit = r.cellIterator(); cit.hasNext();) {
 					HSSFCell c = (HSSFCell)cit.next();
-					if(c.getCellType() == HSSFCell.CELL_TYPE_FORMULA) {
+					if(c.getCellType() == CellType.FORMULA) {
 						evaluator.evaluateFormulaCell(c);
 						
 						// For testing - all should be numeric
-						assertEquals(HSSFCell.CELL_TYPE_NUMERIC, evaluator.evaluateFormulaCell(c));
+						assertEquals(CellType.NUMERIC, evaluator.evaluateFormulaCell(c));
 					}
 				}
 			}
@@ -88,15 +90,15 @@ public final class TestFormulaEvaluatorD
 		// Check now as expected
 		assertEquals(55.7, wb.getSheetAt(0).getRow(0).getCell(2).getNumericCellValue(), 0);
 		assertEquals("SUM(A1:B1)", wb.getSheetAt(0).getRow(0).getCell(2).getCellFormula());
-		assertEquals(HSSFCell.CELL_TYPE_FORMULA, wb.getSheetAt(0).getRow(0).getCell(2).getCellType());
+		assertEquals(CellType.FORMULA, wb.getSheetAt(0).getRow(0).getCell(2).getCellType());
 		
 		assertEquals(-4.6, wb.getSheetAt(0).getRow(1).getCell(2).getNumericCellValue(), 0);
 		assertEquals("SUM(A2:B2)", wb.getSheetAt(0).getRow(1).getCell(2).getCellFormula());
-		assertEquals(HSSFCell.CELL_TYPE_FORMULA, wb.getSheetAt(0).getRow(1).getCell(2).getCellType());
+		assertEquals(CellType.FORMULA, wb.getSheetAt(0).getRow(1).getCell(2).getCellType());
 		
 		assertEquals(22.3, wb.getSheetAt(1).getRow(0).getCell(0).getNumericCellValue(), 0);
 		assertEquals("'S1'!A1", wb.getSheetAt(1).getRow(0).getCell(0).getCellFormula());
-		assertEquals(HSSFCell.CELL_TYPE_FORMULA, wb.getSheetAt(1).getRow(0).getCell(0).getCellType());
+		assertEquals(CellType.FORMULA, wb.getSheetAt(1).getRow(0).getCell(0).getCellType());
 		
 		
 		// Now do the alternate call, which zaps the formulas
@@ -110,7 +112,7 @@ public final class TestFormulaEvaluatorD
 
 				for(Iterator cit = r.cellIterator(); cit.hasNext();) {
 					HSSFCell c = (HSSFCell)cit.next();
-					if(c.getCellType() == HSSFCell.CELL_TYPE_FORMULA) {
+					if(c.getCellType() == CellType.FORMULA) {
 						evaluator.evaluateInCell(c);
 					}
 				}
@@ -118,12 +120,12 @@ public final class TestFormulaEvaluatorD
 		}
 		
 		assertEquals(55.7, wb.getSheetAt(0).getRow(0).getCell(2).getNumericCellValue(), 0);
-		assertEquals(HSSFCell.CELL_TYPE_NUMERIC, wb.getSheetAt(0).getRow(0).getCell(2).getCellType());
+		assertEquals(CellType.NUMERIC, wb.getSheetAt(0).getRow(0).getCell(2).getCellType());
 		
 		assertEquals(-4.6, wb.getSheetAt(0).getRow(1).getCell(2).getNumericCellValue(), 0);
-		assertEquals(HSSFCell.CELL_TYPE_NUMERIC, wb.getSheetAt(0).getRow(1).getCell(2).getCellType());
+		assertEquals(CellType.NUMERIC, wb.getSheetAt(0).getRow(1).getCell(2).getCellType());
 		
 		assertEquals(22.3, wb.getSheetAt(1).getRow(0).getCell(0).getNumericCellValue(), 0);
-		assertEquals(HSSFCell.CELL_TYPE_NUMERIC, wb.getSheetAt(1).getRow(0).getCell(0).getCellType());
+		assertEquals(CellType.NUMERIC, wb.getSheetAt(1).getRow(0).getCell(0).getCellType());
 	}
 }

Modified: poi/trunk/src/testcases/org/apache/poi/hssf/usermodel/TestHSSFDataFormatter.java
URL: http://svn.apache.org/viewvc/poi/trunk/src/testcases/org/apache/poi/hssf/usermodel/TestHSSFDataFormatter.java?rev=1751240&r1=1751239&r2=1751240&view=diff
==============================================================================
--- poi/trunk/src/testcases/org/apache/poi/hssf/usermodel/TestHSSFDataFormatter.java (original)
+++ poi/trunk/src/testcases/org/apache/poi/hssf/usermodel/TestHSSFDataFormatter.java Mon Jul  4 10:15:18 2016
@@ -31,6 +31,7 @@ import java.util.TimeZone;
 
 import org.apache.poi.hssf.HSSFTestDataSamples;
 import org.apache.poi.ss.usermodel.Cell;
+import org.apache.poi.ss.usermodel.CellType;
 import org.apache.poi.ss.usermodel.DateUtil;
 import org.apache.poi.util.LocaleUtil;
 import org.junit.AfterClass;
@@ -216,7 +217,7 @@ public final class TestHSSFDataFormatter
         { // formula cell
             row = sheet.createRow(7);
             HSSFCell cell = row.createCell(0);
-            cell.setCellType(HSSFCell.CELL_TYPE_FORMULA);
+            cell.setCellType(CellType.FORMULA);
             cell.setCellFormula("SUM(12.25,12.25)/100");
             HSSFCellStyle cellStyle = wb.createCellStyle();
             cellStyle.setDataFormat(format.getFormat("##.00%;"));
@@ -383,7 +384,7 @@ public final class TestHSSFDataFormatter
         HSSFRow row = sheet.getRow(0);
         HSSFCell cellA1 = row.getCell(0);
 
-        assertEquals(HSSFCell.CELL_TYPE_NUMERIC, cellA1.getCellType());
+        assertEquals(CellType.NUMERIC, cellA1.getCellType());
         assertEquals(2345.0, cellA1.getNumericCellValue(), 0.0001);
         assertEquals("@", cellA1.getCellStyle().getDataFormatString());
 

Modified: poi/trunk/src/testcases/org/apache/poi/hssf/usermodel/TestHSSFFormulaEvaluator.java
URL: http://svn.apache.org/viewvc/poi/trunk/src/testcases/org/apache/poi/hssf/usermodel/TestHSSFFormulaEvaluator.java?rev=1751240&r1=1751239&r2=1751240&view=diff
==============================================================================
--- poi/trunk/src/testcases/org/apache/poi/hssf/usermodel/TestHSSFFormulaEvaluator.java (original)
+++ poi/trunk/src/testcases/org/apache/poi/hssf/usermodel/TestHSSFFormulaEvaluator.java Mon Jul  4 10:15:18 2016
@@ -33,6 +33,7 @@ import org.apache.poi.ss.formula.eval.Nu
 import org.apache.poi.ss.formula.eval.ValueEval;
 import org.apache.poi.ss.usermodel.BaseTestFormulaEvaluator;
 import org.apache.poi.ss.usermodel.Cell;
+import org.apache.poi.ss.usermodel.CellType;
 import org.apache.poi.ss.usermodel.CellValue;
 import org.apache.poi.ss.usermodel.FormulaError;
 import org.junit.Test;
@@ -54,7 +55,7 @@ public final class TestHSSFFormulaEvalua
 		HSSFCell cell = sheet.getRow(8).getCell(0);
 		HSSFFormulaEvaluator fe = new HSSFFormulaEvaluator(wb);
 		CellValue cv = fe.evaluate(cell);
-		assertEquals(HSSFCell.CELL_TYPE_NUMERIC, cv.getCellType());
+		assertEquals(CellType.NUMERIC, cv.getCellType());
 		assertEquals(3.72, cv.getNumberValue(), 0.0);
 		wb.close();
 	}
@@ -126,7 +127,7 @@ public final class TestHSSFFormulaEvalua
 		try {
 			value = hsf.evaluate(cellA1);
 
-	        assertEquals(Cell.CELL_TYPE_NUMERIC, value.getCellType());
+	        assertEquals(CellType.NUMERIC, value.getCellType());
 	        assertEquals(5.33, value.getNumberValue(), 0.0);
 	        
 		} catch (RuntimeException e) {
@@ -198,8 +199,8 @@ public final class TestHSSFFormulaEvalua
       
       // VLookup on a name in another file
       cell = wb1.getSheetAt(0).getRow(1).getCell(2);
-      assertEquals(Cell.CELL_TYPE_FORMULA, cell.getCellType());
-      assertEquals(Cell.CELL_TYPE_NUMERIC, cell.getCachedFormulaResultType());
+      assertEquals(CellType.FORMULA, cell.getCellType());
+      assertEquals(CellType.NUMERIC, cell.getCachedFormulaResultType());
       assertEquals(12.30, cell.getNumericCellValue(), 0.0001);
       // WARNING - this is wrong!
       // The file name should be showing, but bug #45970 is fixed
@@ -209,8 +210,8 @@ public final class TestHSSFFormulaEvalua
       
       // Simple reference to a name in another file
       cell = wb1.getSheetAt(0).getRow(1).getCell(4);
-      assertEquals(Cell.CELL_TYPE_FORMULA, cell.getCellType());
-      assertEquals(Cell.CELL_TYPE_NUMERIC, cell.getCachedFormulaResultType());
+      assertEquals(CellType.FORMULA, cell.getCellType());
+      assertEquals(CellType.NUMERIC, cell.getCachedFormulaResultType());
       assertEquals(36.90, cell.getNumericCellValue(), 0.0001);
       // TODO Correct this!
       // The file name should be shown too, see bug #56742
@@ -236,14 +237,14 @@ public final class TestHSSFFormulaEvalua
 
       // Re-check VLOOKUP one
       cell = wb1.getSheetAt(0).getRow(1).getCell(2);
-      assertEquals(Cell.CELL_TYPE_FORMULA, cell.getCellType());
-      assertEquals(Cell.CELL_TYPE_NUMERIC, cell.getCachedFormulaResultType());
+      assertEquals(CellType.FORMULA, cell.getCellType());
+      assertEquals(CellType.NUMERIC, cell.getCachedFormulaResultType());
       assertEquals(12.30, cell.getNumericCellValue(), 0.0001);
       
       // Re-check ref one
       cell = wb1.getSheetAt(0).getRow(1).getCell(4);
-      assertEquals(Cell.CELL_TYPE_FORMULA, cell.getCellType());
-      assertEquals(Cell.CELL_TYPE_NUMERIC, cell.getCachedFormulaResultType());
+      assertEquals(CellType.FORMULA, cell.getCellType());
+      assertEquals(CellType.NUMERIC, cell.getCachedFormulaResultType());
       assertEquals(36.90, cell.getNumericCellValue(), 0.0001);
       
       

Modified: poi/trunk/src/testcases/org/apache/poi/ss/format/TestCellFormat.java
URL: http://svn.apache.org/viewvc/poi/trunk/src/testcases/org/apache/poi/ss/format/TestCellFormat.java?rev=1751240&r1=1751239&r2=1751240&view=diff
==============================================================================
--- poi/trunk/src/testcases/org/apache/poi/ss/format/TestCellFormat.java (original)
+++ poi/trunk/src/testcases/org/apache/poi/ss/format/TestCellFormat.java Mon Jul  4 10:15:18 2016
@@ -157,16 +157,16 @@ public class TestCellFormat {
         
         CellFormat cf = CellFormat.getInstance("General");
         
-        // case Cell.CELL_TYPE_BLANK
+        // case CellType.BLANK
         CellFormatResult result0 = cf.apply(cell0);
         assertEquals("", result0.text);
         
-        // case Cell.CELL_TYPE_BOOLEAN
+        // case CellType.BOOLEAN
         cell1.setCellValue(true);
         CellFormatResult result1 = cf.apply(cell1);
         assertEquals("TRUE", result1.text);
         
-        // case Cell.CELL_TYPE_NUMERIC
+        // case CellType.NUMERIC
         cell2.setCellValue(1.23);
         CellFormatResult result2 = cf.apply(cell2);
         assertEquals("1.23", result2.text);
@@ -175,7 +175,7 @@ public class TestCellFormat {
         CellFormatResult result3 = cf.apply(cell3);
         assertEquals("123", result3.text);
         
-        // case Cell.CELL_TYPE_STRING
+        // case CellType.STRING
         cell4.setCellValue("abc");
         CellFormatResult result4 = cf.apply(cell4);
         assertEquals("abc", result4.text);
@@ -198,16 +198,16 @@ public class TestCellFormat {
         
         CellFormat cf = CellFormat.getInstance("@");
         
-        // case Cell.CELL_TYPE_BLANK
+        // case CellType.BLANK
         CellFormatResult result0 = cf.apply(cell0);
         assertEquals("", result0.text);
         
-        // case Cell.CELL_TYPE_BOOLEAN
+        // case CellType.BOOLEAN
         cell1.setCellValue(true);
         CellFormatResult result1 = cf.apply(cell1);
         assertEquals("TRUE", result1.text);
         
-        // case Cell.CELL_TYPE_NUMERIC
+        // case CellType.NUMERIC
         cell2.setCellValue(1.23);
         CellFormatResult result2 = cf.apply(cell2);
         assertEquals("1.23", result2.text);
@@ -216,7 +216,7 @@ public class TestCellFormat {
         CellFormatResult result3 = cf.apply(cell3);
         assertEquals("123", result3.text);
         
-        // case Cell.CELL_TYPE_STRING
+        // case CellType.STRING
         cell4.setCellValue("abc");
         CellFormatResult result4 = cf.apply(cell4);
         assertEquals("abc", result4.text);
@@ -309,18 +309,18 @@ public class TestCellFormat {
         JLabel label3 = new JLabel();
         JLabel label4 = new JLabel();
         
-        // case Cell.CELL_TYPE_BLANK
+        // case CellType.BLANK
         CellFormatResult result0 = cf.apply(label0, cell0);
         assertEquals("", result0.text);
         assertEquals("", label0.getText());
         
-        // case Cell.CELL_TYPE_BOOLEAN
+        // case CellType.BOOLEAN
         cell1.setCellValue(true);
         CellFormatResult result1 = cf.apply(label1, cell1);
         assertEquals("TRUE", result1.text);
         assertEquals("TRUE", label1.getText());
         
-        // case Cell.CELL_TYPE_NUMERIC
+        // case CellType.NUMERIC
         cell2.setCellValue(1.23);
         CellFormatResult result2 = cf.apply(label2, cell2);
         assertEquals("1.23", result2.text);
@@ -331,7 +331,7 @@ public class TestCellFormat {
         assertEquals("123", result3.text);
         assertEquals("123", label3.getText());
         
-        // case Cell.CELL_TYPE_STRING
+        // case CellType.STRING
         cell4.setCellValue("abc");
         CellFormatResult result4 = cf.apply(label4, cell4);
         assertEquals("abc", result4.text);
@@ -361,18 +361,18 @@ public class TestCellFormat {
         JLabel label3 = new JLabel();
         JLabel label4 = new JLabel();
         
-        // case Cell.CELL_TYPE_BLANK
+        // case CellType.BLANK
         CellFormatResult result0 = cf.apply(label0, cell0);
         assertEquals("", result0.text);
         assertEquals("", label0.getText());
         
-        // case Cell.CELL_TYPE_BOOLEAN
+        // case CellType.BOOLEAN
         cell1.setCellValue(true);
         CellFormatResult result1 = cf.apply(label1, cell1);
         assertEquals("TRUE", result1.text);
         assertEquals("TRUE", label1.getText());
         
-        // case Cell.CELL_TYPE_NUMERIC
+        // case CellType.NUMERIC
         cell2.setCellValue(1.23);
         CellFormatResult result2 = cf.apply(label2, cell2);
         assertEquals("1.23", result2.text);
@@ -383,7 +383,7 @@ public class TestCellFormat {
         assertEquals("123", result3.text);
         assertEquals("123", label3.getText());
         
-        // case Cell.CELL_TYPE_STRING
+        // case CellType.STRING
         cell4.setCellValue("abc");
         CellFormatResult result4 = cf.apply(label4, cell4);
         assertEquals("abc", result4.text);

Modified: poi/trunk/src/testcases/org/apache/poi/ss/formula/BaseTestExternalFunctions.java
URL: http://svn.apache.org/viewvc/poi/trunk/src/testcases/org/apache/poi/ss/formula/BaseTestExternalFunctions.java?rev=1751240&r1=1751239&r2=1751240&view=diff
==============================================================================
--- poi/trunk/src/testcases/org/apache/poi/ss/formula/BaseTestExternalFunctions.java (original)
+++ poi/trunk/src/testcases/org/apache/poi/ss/formula/BaseTestExternalFunctions.java Mon Jul  4 10:15:18 2016
@@ -16,7 +16,9 @@
 ==================================================================== */
 package org.apache.poi.ss.formula;
 
-import static org.junit.Assert.*;
+import static org.junit.Assert.assertEquals;
+import static org.junit.Assert.assertTrue;
+import static org.junit.Assert.fail;
 
 import java.io.IOException;
 
@@ -30,6 +32,7 @@ import org.apache.poi.ss.formula.functio
 import org.apache.poi.ss.formula.udf.DefaultUDFFinder;
 import org.apache.poi.ss.formula.udf.UDFFinder;
 import org.apache.poi.ss.usermodel.Cell;
+import org.apache.poi.ss.usermodel.CellType;
 import org.apache.poi.ss.usermodel.FormulaEvaluator;
 import org.apache.poi.ss.usermodel.Sheet;
 import org.apache.poi.ss.usermodel.Workbook;
@@ -146,12 +149,12 @@ public abstract class BaseTestExternalFu
         Cell cell2 = sh.getRow(2).getCell(1);
         assertEquals("ISODD(2)", cell2.getCellFormula());
         assertEquals(false, evaluator.evaluate(cell2).getBooleanValue());
-        assertEquals(Cell.CELL_TYPE_BOOLEAN, evaluator.evaluateFormulaCell(cell2));
+        assertEquals(CellType.BOOLEAN, evaluator.evaluateFormulaCell(cell2));
 
         Cell cell3 = sh.getRow(3).getCell(1);
         assertEquals("ISEVEN(2)", cell3.getCellFormula());
         assertEquals(true, evaluator.evaluate(cell3).getBooleanValue());
-        assertEquals(Cell.CELL_TYPE_BOOLEAN, evaluator.evaluateFormulaCell(cell3));
+        assertEquals(CellType.BOOLEAN, evaluator.evaluateFormulaCell(cell3));
 
         wb.close();
     }

Modified: poi/trunk/src/testcases/org/apache/poi/ss/formula/TestEvaluationCache.java
URL: http://svn.apache.org/viewvc/poi/trunk/src/testcases/org/apache/poi/ss/formula/TestEvaluationCache.java?rev=1751240&r1=1751239&r2=1751240&view=diff
==============================================================================
--- poi/trunk/src/testcases/org/apache/poi/ss/formula/TestEvaluationCache.java (original)
+++ poi/trunk/src/testcases/org/apache/poi/ss/formula/TestEvaluationCache.java Mon Jul  4 10:15:18 2016
@@ -224,14 +224,14 @@ public class TestEvaluationCache extends
 		public void setCellValue(String cellRefText, double value) {
 			HSSFCell cell = getOrCreateCell(cellRefText);
 			// be sure to blank cell, in case it is currently a formula
-			cell.setCellType(HSSFCell.CELL_TYPE_BLANK);
+			cell.setCellType(CellType.BLANK);
 			// otherwise this line will only set the formula cached result;
 			cell.setCellValue(value);
 			_evaluator.notifyUpdateCell(wrapCell(cell));
 		}
 		public void clearCell(String cellRefText) {
 			HSSFCell cell = getOrCreateCell(cellRefText);
-			cell.setCellType(HSSFCell.CELL_TYPE_BLANK);
+			cell.setCellType(CellType.BLANK);
 			_evaluator.notifyUpdateCell(wrapCell(cell));
 		}
 
@@ -598,7 +598,7 @@ public class TestEvaluationCache extends
 		cv = fe.evaluate(cellA1);
 		assertEquals(3.7, cv.getNumberValue(), 0.0);
 
-		cellB1.setCellType(HSSFCell.CELL_TYPE_BLANK);
+		cellB1.setCellType(CellType.BLANK);
 		fe.notifyUpdateCell(cellB1);
 		cv = fe.evaluate(cellA1); // B1 was used to evaluate A1
 		assertEquals(2.2, cv.getNumberValue(), 0.0);

Modified: poi/trunk/src/testcases/org/apache/poi/ss/formula/TestMissingWorkbook.java
URL: http://svn.apache.org/viewvc/poi/trunk/src/testcases/org/apache/poi/ss/formula/TestMissingWorkbook.java?rev=1751240&r1=1751239&r2=1751240&view=diff
==============================================================================
--- poi/trunk/src/testcases/org/apache/poi/ss/formula/TestMissingWorkbook.java (original)
+++ poi/trunk/src/testcases/org/apache/poi/ss/formula/TestMissingWorkbook.java Mon Jul  4 10:15:18 2016
@@ -27,6 +27,7 @@ import junit.framework.TestCase;
 
 import org.apache.poi.hssf.HSSFTestDataSamples;
 import org.apache.poi.ss.usermodel.Cell;
+import org.apache.poi.ss.usermodel.CellType;
 import org.apache.poi.ss.usermodel.FormulaEvaluator;
 import org.apache.poi.ss.usermodel.Row;
 import org.apache.poi.ss.usermodel.Sheet;
@@ -66,7 +67,7 @@ public class TestMissingWorkbook extends
 		Row lARow = lSheet.getRow(0);
 		Cell lA1Cell = lARow.getCell(0);
 		
-		assertEquals(Cell.CELL_TYPE_FORMULA, lA1Cell.getCellType());
+		assertEquals(CellType.FORMULA, lA1Cell.getCellType());
 		try {
 			evaluator.evaluateFormulaCell(lA1Cell);
 			fail("Missing external workbook reference exception expected!");
@@ -81,9 +82,9 @@ public class TestMissingWorkbook extends
 		Cell lB1Cell = lSheet.getRow(1).getCell(0);
 		Cell lC1Cell = lSheet.getRow(2).getCell(0);
 		
-		assertEquals(Cell.CELL_TYPE_FORMULA, lA1Cell.getCellType());
-		assertEquals(Cell.CELL_TYPE_FORMULA, lB1Cell.getCellType());
-		assertEquals(Cell.CELL_TYPE_FORMULA, lC1Cell.getCellType());
+		assertEquals(CellType.FORMULA, lA1Cell.getCellType());
+		assertEquals(CellType.FORMULA, lB1Cell.getCellType());
+		assertEquals(CellType.FORMULA, lC1Cell.getCellType());
 
 		// Check cached values
         assertEquals(10.0d, lA1Cell.getNumericCellValue(), 0.00001d);
@@ -94,9 +95,9 @@ public class TestMissingWorkbook extends
 		FormulaEvaluator evaluator = mainWorkbook.getCreationHelper().createFormulaEvaluator();
         evaluator.setIgnoreMissingWorkbooks(true);
 
-		assertEquals(Cell.CELL_TYPE_NUMERIC, evaluator.evaluateFormulaCell(lA1Cell));
-		assertEquals(Cell.CELL_TYPE_STRING,  evaluator.evaluateFormulaCell(lB1Cell));
-		assertEquals(Cell.CELL_TYPE_BOOLEAN, evaluator.evaluateFormulaCell(lC1Cell));
+		assertEquals(CellType.NUMERIC, evaluator.evaluateFormulaCell(lA1Cell));
+		assertEquals(CellType.STRING,  evaluator.evaluateFormulaCell(lB1Cell));
+		assertEquals(CellType.BOOLEAN, evaluator.evaluateFormulaCell(lC1Cell));
 
 		assertEquals(10.0d, lA1Cell.getNumericCellValue(), 0.00001d);
 		assertEquals("POI rocks!", lB1Cell.getStringCellValue());
@@ -110,9 +111,9 @@ public class TestMissingWorkbook extends
 		Cell lB1Cell = lSheet.getRow(1).getCell(0);
 		Cell lC1Cell = lSheet.getRow(2).getCell(0);
 		
-		assertEquals(Cell.CELL_TYPE_FORMULA, lA1Cell.getCellType());
-		assertEquals(Cell.CELL_TYPE_FORMULA, lB1Cell.getCellType());
-		assertEquals(Cell.CELL_TYPE_FORMULA, lC1Cell.getCellType());
+		assertEquals(CellType.FORMULA, lA1Cell.getCellType());
+		assertEquals(CellType.FORMULA, lB1Cell.getCellType());
+		assertEquals(CellType.FORMULA, lC1Cell.getCellType());
 
 		FormulaEvaluator lMainWorkbookEvaluator = mainWorkbook.getCreationHelper().createFormulaEvaluator();
 		FormulaEvaluator lSourceEvaluator = sourceWorkbook.getCreationHelper().createFormulaEvaluator();
@@ -121,9 +122,9 @@ public class TestMissingWorkbook extends
 		workbooks.put(SOURCE_DUMMY_WORKBOOK_FILENAME, lSourceEvaluator);
 		lMainWorkbookEvaluator.setupReferencedWorkbooks(workbooks);
 		
-		assertEquals(Cell.CELL_TYPE_NUMERIC, lMainWorkbookEvaluator.evaluateFormulaCell(lA1Cell));
-		assertEquals(Cell.CELL_TYPE_STRING, lMainWorkbookEvaluator.evaluateFormulaCell(lB1Cell));
-		assertEquals(Cell.CELL_TYPE_BOOLEAN, lMainWorkbookEvaluator.evaluateFormulaCell(lC1Cell));
+		assertEquals(CellType.NUMERIC, lMainWorkbookEvaluator.evaluateFormulaCell(lA1Cell));
+		assertEquals(CellType.STRING, lMainWorkbookEvaluator.evaluateFormulaCell(lB1Cell));
+		assertEquals(CellType.BOOLEAN, lMainWorkbookEvaluator.evaluateFormulaCell(lC1Cell));
 
 		assertEquals(20.0d, lA1Cell.getNumericCellValue(), 0.00001d);
 		assertEquals("Apache rocks!", lB1Cell.getStringCellValue());

Modified: poi/trunk/src/testcases/org/apache/poi/ss/formula/atp/TestIfError.java
URL: http://svn.apache.org/viewvc/poi/trunk/src/testcases/org/apache/poi/ss/formula/atp/TestIfError.java?rev=1751240&r1=1751239&r2=1751240&view=diff
==============================================================================
--- poi/trunk/src/testcases/org/apache/poi/ss/formula/atp/TestIfError.java (original)
+++ poi/trunk/src/testcases/org/apache/poi/ss/formula/atp/TestIfError.java Mon Jul  4 10:15:18 2016
@@ -16,16 +16,17 @@
 ==================================================================== */
 package org.apache.poi.ss.formula.atp;
 
-import junit.framework.TestCase;
-
 import org.apache.poi.hssf.usermodel.HSSFWorkbook;
 import org.apache.poi.ss.usermodel.Cell;
+import org.apache.poi.ss.usermodel.CellType;
 import org.apache.poi.ss.usermodel.FormulaEvaluator;
 import org.apache.poi.ss.usermodel.Row;
 import org.apache.poi.ss.usermodel.Sheet;
 import org.apache.poi.ss.usermodel.Workbook;
 import org.apache.poi.ss.util.CellReference;
 
+import junit.framework.TestCase;
+
 /**
  * Testcase for 'Analysis Toolpak' function IFERROR()
  * 
@@ -45,11 +46,11 @@ public class TestIfError extends TestCas
         Row row2 = sh.createRow(1);
 
         // Create cells
-        row1.createCell(0, Cell.CELL_TYPE_NUMERIC);
-        row1.createCell(1, Cell.CELL_TYPE_NUMERIC);
-        row1.createCell(2, Cell.CELL_TYPE_NUMERIC);
-        row2.createCell(0, Cell.CELL_TYPE_NUMERIC);
-        row2.createCell(1, Cell.CELL_TYPE_NUMERIC);
+        row1.createCell(0, CellType.NUMERIC);
+        row1.createCell(1, CellType.NUMERIC);
+        row1.createCell(2, CellType.NUMERIC);
+        row2.createCell(0, CellType.NUMERIC);
+        row2.createCell(1, CellType.NUMERIC);
 
         // Create references
         CellReference a1 = new CellReference("A1");
@@ -77,18 +78,18 @@ public class TestIfError extends TestCas
         FormulaEvaluator evaluator = wb.getCreationHelper().createFormulaEvaluator();
 
         assertEquals("Checks that the cell is numeric",
-        		Cell.CELL_TYPE_NUMERIC, evaluator.evaluate(cell1).getCellType());
+        		CellType.NUMERIC, evaluator.evaluate(cell1).getCellType());
         assertEquals("Divides 210 by 35 and returns 6.0",
                 6.0, evaluator.evaluate(cell1).getNumberValue(), accuracy);
         
         
         assertEquals("Checks that the cell is numeric",
-        		Cell.CELL_TYPE_STRING, evaluator.evaluate(cell2).getCellType());        
+        		CellType.STRING, evaluator.evaluate(cell2).getCellType());        
         assertEquals("Rounds -10 to a nearest multiple of -3 (-9)",
                 "Error in calculation", evaluator.evaluate(cell2).getStringValue());
         
         assertEquals("Check that C1 returns string", 
-        		Cell.CELL_TYPE_STRING, evaluator.evaluate(cell3).getCellType());
+        		CellType.STRING, evaluator.evaluate(cell3).getCellType());
         assertEquals("Check that C1 returns string \"error\"", 
         		"error", evaluator.evaluate(cell3).getStringValue());
     }

Modified: poi/trunk/src/testcases/org/apache/poi/ss/formula/atp/TestRandBetween.java
URL: http://svn.apache.org/viewvc/poi/trunk/src/testcases/org/apache/poi/ss/formula/atp/TestRandBetween.java?rev=1751240&r1=1751239&r2=1751240&view=diff
==============================================================================
--- poi/trunk/src/testcases/org/apache/poi/ss/formula/atp/TestRandBetween.java (original)
+++ poi/trunk/src/testcases/org/apache/poi/ss/formula/atp/TestRandBetween.java Mon Jul  4 10:15:18 2016
@@ -21,6 +21,7 @@ import junit.framework.TestCase;
 import org.apache.poi.hssf.HSSFTestDataSamples;
 import org.apache.poi.ss.formula.eval.ErrorEval;
 import org.apache.poi.ss.usermodel.Cell;
+import org.apache.poi.ss.usermodel.CellType;
 import org.apache.poi.ss.usermodel.FormulaEvaluator;
 import org.apache.poi.ss.usermodel.Row;
 import org.apache.poi.ss.usermodel.Sheet;
@@ -49,7 +50,7 @@ public class TestRandBetween extends Tes
 		Row row = sheet.createRow(0);
 		bottomValueCell = row.createCell(0);
 		topValueCell = row.createCell(1);
-		formulaCell = row.createCell(2, Cell.CELL_TYPE_FORMULA);
+		formulaCell = row.createCell(2, CellType.FORMULA);
 	}
 	
 	@Override
@@ -113,7 +114,7 @@ public class TestRandBetween extends Tes
 	public void testRandBetweenTopBlank() {
 
 		bottomValueCell.setCellValue(-1);		
-		topValueCell.setCellType(Cell.CELL_TYPE_BLANK);
+		topValueCell.setCellType(CellType.BLANK);
 		formulaCell.setCellFormula("RANDBETWEEN($A$1,$B$1)");
 		evaluator.clearAllCachedResultValues();
 		evaluator.evaluateFormulaCell(formulaCell);
@@ -130,7 +131,7 @@ public class TestRandBetween extends Tes
 		formulaCell.setCellFormula("RANDBETWEEN($A$1,$B$1)");
 		evaluator.clearAllCachedResultValues();
 		evaluator.evaluateFormulaCell(formulaCell);
-		assertEquals(Cell.CELL_TYPE_ERROR, formulaCell.getCachedFormulaResultType());
+		assertEquals(CellType.ERROR, formulaCell.getCachedFormulaResultType());
 		assertEquals(ErrorEval.VALUE_INVALID.getErrorCode(), formulaCell.getErrorCellValue());
 		
 		
@@ -140,7 +141,7 @@ public class TestRandBetween extends Tes
 		formulaCell.setCellFormula("RANDBETWEEN($A$1,$B$1)");
 		evaluator.clearAllCachedResultValues();
 		evaluator.evaluateFormulaCell(formulaCell);
-		assertEquals(Cell.CELL_TYPE_ERROR, formulaCell.getCachedFormulaResultType());
+		assertEquals(CellType.ERROR, formulaCell.getCachedFormulaResultType());
 		assertEquals(ErrorEval.VALUE_INVALID.getErrorCode(), formulaCell.getErrorCellValue());
 
 		// Check case where both inputs are of wrong type
@@ -149,7 +150,7 @@ public class TestRandBetween extends Tes
 		formulaCell.setCellFormula("RANDBETWEEN($A$1,$B$1)");
 		evaluator.clearAllCachedResultValues();
 		evaluator.evaluateFormulaCell(formulaCell);
-		assertEquals(Cell.CELL_TYPE_ERROR, formulaCell.getCachedFormulaResultType());
+		assertEquals(CellType.ERROR, formulaCell.getCachedFormulaResultType());
 		assertEquals(ErrorEval.VALUE_INVALID.getErrorCode(), formulaCell.getErrorCellValue());
 	
 	}
@@ -165,14 +166,14 @@ public class TestRandBetween extends Tes
 		formulaCell.setCellFormula("RANDBETWEEN($A$1,$B$1)");
 		evaluator.clearAllCachedResultValues();
 		evaluator.evaluateFormulaCell(formulaCell);
-		assertEquals(Cell.CELL_TYPE_ERROR, formulaCell.getCachedFormulaResultType());
+		assertEquals(CellType.ERROR, formulaCell.getCachedFormulaResultType());
 		assertEquals(ErrorEval.NUM_ERROR.getErrorCode(), formulaCell.getErrorCellValue());		
 		bottomValueCell.setCellValue(1);		
-		topValueCell.setCellType(Cell.CELL_TYPE_BLANK);
+		topValueCell.setCellType(CellType.BLANK);
 		formulaCell.setCellFormula("RANDBETWEEN($A$1,$B$1)");
 		evaluator.clearAllCachedResultValues();
 		evaluator.evaluateFormulaCell(formulaCell);
-		assertEquals(Cell.CELL_TYPE_ERROR, formulaCell.getCachedFormulaResultType());
+		assertEquals(CellType.ERROR, formulaCell.getCachedFormulaResultType());
 		assertEquals(ErrorEval.NUM_ERROR.getErrorCode(), formulaCell.getErrorCellValue());
 	}
 	

Modified: poi/trunk/src/testcases/org/apache/poi/ss/formula/atp/TestYearFracCalculatorFromSpreadsheet.java
URL: http://svn.apache.org/viewvc/poi/trunk/src/testcases/org/apache/poi/ss/formula/atp/TestYearFracCalculatorFromSpreadsheet.java?rev=1751240&r1=1751239&r2=1751240&view=diff
==============================================================================
--- poi/trunk/src/testcases/org/apache/poi/ss/formula/atp/TestYearFracCalculatorFromSpreadsheet.java (original)
+++ poi/trunk/src/testcases/org/apache/poi/ss/formula/atp/TestYearFracCalculatorFromSpreadsheet.java Mon Jul  4 10:15:18 2016
@@ -32,6 +32,7 @@ import org.apache.poi.hssf.usermodel.HSS
 import org.apache.poi.hssf.usermodel.HSSFSheet;
 import org.apache.poi.hssf.usermodel.HSSFWorkbook;
 import org.apache.poi.ss.formula.eval.EvaluationException;
+import org.apache.poi.ss.usermodel.CellType;
 import org.apache.poi.ss.usermodel.Row;
 import org.apache.poi.util.LocaleUtil;
 import org.junit.Test;
@@ -62,7 +63,7 @@ public final class TestYearFracCalculato
 			HSSFRow row = (HSSFRow) rowIterator.next();
 			
 			HSSFCell cell = row.getCell(SS.YEARFRAC_FORMULA_COLUMN);
-			if (cell == null || cell.getCellType() != HSSFCell.CELL_TYPE_FORMULA) {
+			if (cell == null || cell.getCellType() != CellType.FORMULA) {
 				continue;
 			}
             processRow(row, cell, formulaEvaluator);

Modified: poi/trunk/src/testcases/org/apache/poi/ss/formula/eval/BaseTestCircularReferences.java
URL: http://svn.apache.org/viewvc/poi/trunk/src/testcases/org/apache/poi/ss/formula/eval/BaseTestCircularReferences.java?rev=1751240&r1=1751239&r2=1751240&view=diff
==============================================================================
--- poi/trunk/src/testcases/org/apache/poi/ss/formula/eval/BaseTestCircularReferences.java (original)
+++ poi/trunk/src/testcases/org/apache/poi/ss/formula/eval/BaseTestCircularReferences.java Mon Jul  4 10:15:18 2016
@@ -24,6 +24,7 @@ import java.io.IOException;
 
 import org.apache.poi.ss.ITestDataProvider;
 import org.apache.poi.ss.usermodel.Cell;
+import org.apache.poi.ss.usermodel.CellType;
 import org.apache.poi.ss.usermodel.CellValue;
 import org.apache.poi.ss.usermodel.FormulaEvaluator;
 import org.apache.poi.ss.usermodel.Row;
@@ -65,7 +66,7 @@ public abstract class BaseTestCircularRe
      * Makes sure that the specified evaluated cell value represents a circular reference error.
      */
     private static void confirmCycleErrorCode(CellValue cellValue) {
-        assertTrue(cellValue.getCellType() == Cell.CELL_TYPE_ERROR);
+        assertTrue(cellValue.getCellType() == CellType.ERROR);
         assertEquals(ErrorEval.CIRCULAR_REF_ERROR.getErrorCode(), cellValue.getErrorValue());
     }
 
@@ -95,7 +96,7 @@ public abstract class BaseTestCircularRe
 
         CellValue cellValue = evaluateWithCycles(wb, testCell);
 
-        assertTrue(cellValue.getCellType() == Cell.CELL_TYPE_NUMERIC);
+        assertTrue(cellValue.getCellType() == CellType.NUMERIC);
         assertEquals(2, cellValue.getNumberValue(), 0);
         wb.close();
     }
@@ -165,10 +166,10 @@ public abstract class BaseTestCircularRe
 
         // Happy day flow - evaluate A1 first
         cv = fe.evaluate(cellA1);
-        assertEquals(Cell.CELL_TYPE_NUMERIC, cv.getCellType());
+        assertEquals(CellType.NUMERIC, cv.getCellType());
         assertEquals(42.0, cv.getNumberValue(), 0.0);
         cv = fe.evaluate(cellB1); // no circ-ref-error because A1 result is cached
-        assertEquals(Cell.CELL_TYPE_NUMERIC, cv.getCellType());
+        assertEquals(CellType.NUMERIC, cv.getCellType());
         assertEquals(46.0, cv.getNumberValue(), 0.0);
 
         // Show the bug - evaluate another cell from the loop first
@@ -176,13 +177,13 @@ public abstract class BaseTestCircularRe
         cv = fe.evaluate(cellB1);
         // Identified bug 46898
         assertNotEquals(cv.getCellType(), ErrorEval.CIRCULAR_REF_ERROR.getErrorCode());
-        assertEquals(Cell.CELL_TYPE_NUMERIC, cv.getCellType());
+        assertEquals(CellType.NUMERIC, cv.getCellType());
         assertEquals(46.0, cv.getNumberValue(), 0.0);
 
         // start evaluation on another cell
         fe.clearAllCachedResultValues();
         cv = fe.evaluate(cellE1);
-        assertEquals(Cell.CELL_TYPE_NUMERIC, cv.getCellType());
+        assertEquals(CellType.NUMERIC, cv.getCellType());
         assertEquals(43.0, cv.getNumberValue(), 0.0);
         
         wb.close();

Modified: poi/trunk/src/testcases/org/apache/poi/ss/formula/eval/TestFormulaBugs.java
URL: http://svn.apache.org/viewvc/poi/trunk/src/testcases/org/apache/poi/ss/formula/eval/TestFormulaBugs.java?rev=1751240&r1=1751239&r2=1751240&view=diff
==============================================================================
--- poi/trunk/src/testcases/org/apache/poi/ss/formula/eval/TestFormulaBugs.java (original)
+++ poi/trunk/src/testcases/org/apache/poi/ss/formula/eval/TestFormulaBugs.java Mon Jul  4 10:15:18 2016
@@ -58,7 +58,7 @@ public final class TestFormulaBugs {
 		FormulaEvaluator fe = wb.getCreationHelper().createFormulaEvaluator();
 		CellValue cv = fe.evaluate(cell);
 
-		assertEquals(Cell.CELL_TYPE_NUMERIC, cv.getCellType());
+		assertEquals(CellType.NUMERIC, cv.getCellType());
 		assertEquals(3.0, cv.getNumberValue(), 0.0);
 		
 		wb.close();
@@ -106,11 +106,11 @@ public final class TestFormulaBugs {
 		FormulaEvaluator fe = wb.getCreationHelper().createFormulaEvaluator();
 		CellValue cv;
 		cv = fe.evaluate(cell);
-		assertEquals(Cell.CELL_TYPE_NUMERIC, cv.getCellType());
+		assertEquals(CellType.NUMERIC, cv.getCellType());
 		assertEquals(1.0, cv.getNumberValue(), 0.0);
 		
 		cv = fe.evaluate(row.getCell(1));
-		assertEquals(Cell.CELL_TYPE_BOOLEAN, cv.getCellType());
+		assertEquals(CellType.BOOLEAN, cv.getCellType());
 		assertEquals(true, cv.getBooleanValue());
 		
 		wb.close();
@@ -161,7 +161,7 @@ public final class TestFormulaBugs {
 		FormulaEvaluator fe = wb.getCreationHelper().createFormulaEvaluator();
 		CellValue cv = fe.evaluate(cell);
 
-		assertEquals(Cell.CELL_TYPE_NUMERIC, cv.getCellType());
+		assertEquals(CellType.NUMERIC, cv.getCellType());
 		assertEquals(expectedResult, cv.getNumberValue(), 0.0);
 
 		wb.close();

Modified: poi/trunk/src/testcases/org/apache/poi/ss/formula/eval/TestPercentEval.java
URL: http://svn.apache.org/viewvc/poi/trunk/src/testcases/org/apache/poi/ss/formula/eval/TestPercentEval.java?rev=1751240&r1=1751239&r2=1751240&view=diff
==============================================================================
--- poi/trunk/src/testcases/org/apache/poi/ss/formula/eval/TestPercentEval.java (original)
+++ poi/trunk/src/testcases/org/apache/poi/ss/formula/eval/TestPercentEval.java Mon Jul  4 10:15:18 2016
@@ -27,6 +27,7 @@ import org.apache.poi.hssf.usermodel.HSS
 import org.apache.poi.hssf.usermodel.HSSFRow;
 import org.apache.poi.hssf.usermodel.HSSFSheet;
 import org.apache.poi.hssf.usermodel.HSSFWorkbook;
+import org.apache.poi.ss.usermodel.CellType;
 import org.apache.poi.ss.usermodel.CellValue;
 
 /**
@@ -77,7 +78,7 @@ public final class TestPercentEval exten
 			// else some other unexpected error
 			throw e;
 		}
-		assertEquals(HSSFCell.CELL_TYPE_NUMERIC, cv.getCellType());
+		assertEquals(CellType.NUMERIC, cv.getCellType());
 		assertEquals(0.5, cv.getNumberValue(), 0.0);
 	}
 }

Modified: poi/trunk/src/testcases/org/apache/poi/ss/formula/functions/CountifsTests.java
URL: http://svn.apache.org/viewvc/poi/trunk/src/testcases/org/apache/poi/ss/formula/functions/CountifsTests.java?rev=1751240&r1=1751239&r2=1751240&view=diff
==============================================================================
--- poi/trunk/src/testcases/org/apache/poi/ss/formula/functions/CountifsTests.java (original)
+++ poi/trunk/src/testcases/org/apache/poi/ss/formula/functions/CountifsTests.java Mon Jul  4 10:15:18 2016
@@ -29,11 +29,11 @@ public class CountifsTests extends TestC
         HSSFWorkbook workbook = new HSSFWorkbook();
         Sheet sheet = workbook.createSheet("test");
         Row row1 = sheet.createRow(0);
-        Cell cellA1 = row1.createCell(0, Cell.CELL_TYPE_FORMULA);
-        Cell cellB1 = row1.createCell(1, Cell.CELL_TYPE_NUMERIC);
-        Cell cellC1 = row1.createCell(2, Cell.CELL_TYPE_NUMERIC);
-        Cell cellD1 = row1.createCell(3, Cell.CELL_TYPE_NUMERIC);
-        Cell cellE1 = row1.createCell(4, Cell.CELL_TYPE_NUMERIC);
+        Cell cellA1 = row1.createCell(0, CellType.FORMULA);
+        Cell cellB1 = row1.createCell(1, CellType.NUMERIC);
+        Cell cellC1 = row1.createCell(2, CellType.NUMERIC);
+        Cell cellD1 = row1.createCell(3, CellType.NUMERIC);
+        Cell cellE1 = row1.createCell(4, CellType.NUMERIC);
         cellB1.setCellValue(1);
         cellC1.setCellValue(1);
         cellD1.setCellValue(2);
@@ -49,7 +49,7 @@ public class CountifsTests extends TestC
         HSSFWorkbook workbook = new HSSFWorkbook();
         Sheet sheet = workbook.createSheet("test");
         Row row1 = sheet.createRow(0);
-        Cell cellA1 = row1.createCell(0, Cell.CELL_TYPE_FORMULA);
+        Cell cellA1 = row1.createCell(0, CellType.FORMULA);
         cellA1.setCellFormula("COUNTIFS()");
         FormulaEvaluator evaluator = workbook.getCreationHelper().createFormulaEvaluator();
         CellValue evaluate = evaluator.evaluate(cellA1);

Modified: poi/trunk/src/testcases/org/apache/poi/ss/formula/functions/TestAddress.java
URL: http://svn.apache.org/viewvc/poi/trunk/src/testcases/org/apache/poi/ss/formula/functions/TestAddress.java?rev=1751240&r1=1751239&r2=1751240&view=diff
==============================================================================
--- poi/trunk/src/testcases/org/apache/poi/ss/formula/functions/TestAddress.java (original)
+++ poi/trunk/src/testcases/org/apache/poi/ss/formula/functions/TestAddress.java Mon Jul  4 10:15:18 2016
@@ -19,6 +19,7 @@ package org.apache.poi.ss.formula.functi
 import org.apache.poi.hssf.usermodel.HSSFCell;
 import org.apache.poi.hssf.usermodel.HSSFFormulaEvaluator;
 import org.apache.poi.hssf.usermodel.HSSFWorkbook;
+import org.apache.poi.ss.usermodel.CellType;
 import org.apache.poi.ss.usermodel.CellValue;
 
 import junit.framework.TestCase;
@@ -72,7 +73,7 @@ public final class TestAddress extends T
         cell.setCellFormula(formulaText);
         fe.notifyUpdateCell(cell);
         CellValue result = fe.evaluate(cell);
-        assertEquals(result.getCellType(), HSSFCell.CELL_TYPE_STRING);
+        assertEquals(result.getCellType(), CellType.STRING);
         assertEquals(expectedResult, result.getStringValue());
     }
 }

Modified: poi/trunk/src/testcases/org/apache/poi/ss/formula/functions/TestCalendarFieldFunction.java
URL: http://svn.apache.org/viewvc/poi/trunk/src/testcases/org/apache/poi/ss/formula/functions/TestCalendarFieldFunction.java?rev=1751240&r1=1751239&r2=1751240&view=diff
==============================================================================
--- poi/trunk/src/testcases/org/apache/poi/ss/formula/functions/TestCalendarFieldFunction.java (original)
+++ poi/trunk/src/testcases/org/apache/poi/ss/formula/functions/TestCalendarFieldFunction.java Mon Jul  4 10:15:18 2016
@@ -17,16 +17,16 @@
 
 package org.apache.poi.ss.formula.functions;
 
-import junit.framework.AssertionFailedError;
-import junit.framework.TestCase;
-
 import org.apache.poi.hssf.usermodel.HSSFCell;
 import org.apache.poi.hssf.usermodel.HSSFFormulaEvaluator;
 import org.apache.poi.hssf.usermodel.HSSFSheet;
 import org.apache.poi.hssf.usermodel.HSSFWorkbook;
-import org.apache.poi.ss.usermodel.Cell;
+import org.apache.poi.ss.usermodel.CellType;
 import org.apache.poi.ss.usermodel.CellValue;
 
+import junit.framework.AssertionFailedError;
+import junit.framework.TestCase;
+
 /**
  * Test for YEAR / MONTH / DAY / HOUR / MINUTE / SECOND
  */
@@ -39,7 +39,7 @@ public final class TestCalendarFieldFunc
         HSSFWorkbook wb = new HSSFWorkbook();
         HSSFSheet sheet = wb.createSheet("new sheet");
         cell11 = sheet.createRow(0).createCell(0);
-        cell11.setCellType(HSSFCell.CELL_TYPE_FORMULA);
+        cell11.setCellType(CellType.FORMULA);
         evaluator = new HSSFFormulaEvaluator(wb);
     }
 
@@ -103,7 +103,7 @@ public final class TestCalendarFieldFunc
         cell11.setCellFormula(formulaText);
         evaluator.clearAllCachedResultValues();
         CellValue cv = evaluator.evaluate(cell11);
-        if (cv.getCellType() != Cell.CELL_TYPE_NUMERIC) {
+        if (cv.getCellType() != CellType.NUMERIC) {
             throw new AssertionFailedError("Wrong result type: " + cv.formatAsString());
         }
         double actualValue = cv.getNumberValue();

Modified: poi/trunk/src/testcases/org/apache/poi/ss/formula/functions/TestClean.java
URL: http://svn.apache.org/viewvc/poi/trunk/src/testcases/org/apache/poi/ss/formula/functions/TestClean.java?rev=1751240&r1=1751239&r2=1751240&view=diff
==============================================================================
--- poi/trunk/src/testcases/org/apache/poi/ss/formula/functions/TestClean.java (original)
+++ poi/trunk/src/testcases/org/apache/poi/ss/formula/functions/TestClean.java Mon Jul  4 10:15:18 2016
@@ -19,6 +19,7 @@ package org.apache.poi.ss.formula.functi
 import org.apache.poi.hssf.usermodel.HSSFCell;
 import org.apache.poi.hssf.usermodel.HSSFFormulaEvaluator;
 import org.apache.poi.hssf.usermodel.HSSFWorkbook;
+import org.apache.poi.ss.usermodel.CellType;
 import org.apache.poi.ss.usermodel.CellValue;
 
 import junit.framework.TestCase;
@@ -59,7 +60,7 @@ public final class TestClean extends Tes
         cell.setCellFormula(formulaText);
         fe.notifyUpdateCell(cell);
         CellValue result = fe.evaluate(cell);
-        assertEquals(result.getCellType(), HSSFCell.CELL_TYPE_STRING);
+        assertEquals(result.getCellType(), CellType.STRING);
         assertEquals(expectedResult, result.getStringValue());
     }
 }

Modified: poi/trunk/src/testcases/org/apache/poi/ss/formula/functions/TestCountFuncs.java
URL: http://svn.apache.org/viewvc/poi/trunk/src/testcases/org/apache/poi/ss/formula/functions/TestCountFuncs.java?rev=1751240&r1=1751239&r2=1751240&view=diff
==============================================================================
--- poi/trunk/src/testcases/org/apache/poi/ss/formula/functions/TestCountFuncs.java (original)
+++ poi/trunk/src/testcases/org/apache/poi/ss/formula/functions/TestCountFuncs.java Mon Jul  4 10:15:18 2016
@@ -17,10 +17,12 @@
 
 package org.apache.poi.ss.formula.functions;
 
-import junit.framework.AssertionFailedError;
-import junit.framework.TestCase;
-
 import org.apache.poi.hssf.HSSFTestDataSamples;
+import org.apache.poi.hssf.usermodel.HSSFCell;
+import org.apache.poi.hssf.usermodel.HSSFFormulaEvaluator;
+import org.apache.poi.hssf.usermodel.HSSFRow;
+import org.apache.poi.hssf.usermodel.HSSFSheet;
+import org.apache.poi.hssf.usermodel.HSSFWorkbook;
 import org.apache.poi.ss.formula.eval.AreaEval;
 import org.apache.poi.ss.formula.eval.BlankEval;
 import org.apache.poi.ss.formula.eval.BoolEval;
@@ -30,15 +32,14 @@ import org.apache.poi.ss.formula.eval.Op
 import org.apache.poi.ss.formula.eval.StringEval;
 import org.apache.poi.ss.formula.eval.ValueEval;
 import org.apache.poi.ss.formula.functions.CountUtils.I_MatchPredicate;
-import org.apache.poi.hssf.usermodel.HSSFCell;
-import org.apache.poi.hssf.usermodel.HSSFFormulaEvaluator;
-import org.apache.poi.hssf.usermodel.HSSFRow;
-import org.apache.poi.hssf.usermodel.HSSFSheet;
-import org.apache.poi.hssf.usermodel.HSSFWorkbook;
+import org.apache.poi.ss.usermodel.CellType;
 import org.apache.poi.ss.usermodel.CellValue;
 import org.apache.poi.ss.usermodel.FormulaEvaluator;
 import org.apache.poi.ss.util.CellReference;
 
+import junit.framework.AssertionFailedError;
+import junit.framework.TestCase;
+
 /**
  * Test cases for COUNT(), COUNTA() COUNTIF(), COUNTBLANK()
  */
@@ -504,9 +505,9 @@ public final class TestCountFuncs extend
         for (int rowIx=7; rowIx<=12; rowIx++) {
             HSSFRow row = sheet1.getRow(rowIx-1);
             HSSFCell cellA = row.getCell(0);  // cell containing a formula with COUNTIF
-            assertEquals(HSSFCell.CELL_TYPE_FORMULA, cellA.getCellType());
+            assertEquals(CellType.FORMULA, cellA.getCellType());
             HSSFCell cellC = row.getCell(2);  // cell with a reference value
-            assertEquals(HSSFCell.CELL_TYPE_NUMERIC, cellC.getCellType());
+            assertEquals(CellType.NUMERIC, cellC.getCellType());
 
             CellValue cv = fe.evaluate(cellA);
             double actualValue = cv.getNumberValue();
@@ -522,9 +523,9 @@ public final class TestCountFuncs extend
         for (int rowIx=9; rowIx<=14; rowIx++) {
             HSSFRow row = sheet2.getRow(rowIx-1);
             HSSFCell cellA = row.getCell(0);  // cell containing a formula with COUNTIF
-            assertEquals(HSSFCell.CELL_TYPE_FORMULA, cellA.getCellType());
+            assertEquals(CellType.FORMULA, cellA.getCellType());
             HSSFCell cellC = row.getCell(2);  // cell with a reference value
-            assertEquals(HSSFCell.CELL_TYPE_NUMERIC, cellC.getCellType());
+            assertEquals(CellType.NUMERIC, cellC.getCellType());
 
             CellValue cv = fe.evaluate(cellA);
             double actualValue = cv.getNumberValue();

Modified: poi/trunk/src/testcases/org/apache/poi/ss/formula/functions/TestDate.java
URL: http://svn.apache.org/viewvc/poi/trunk/src/testcases/org/apache/poi/ss/formula/functions/TestDate.java?rev=1751240&r1=1751239&r2=1751240&view=diff
==============================================================================
--- poi/trunk/src/testcases/org/apache/poi/ss/formula/functions/TestDate.java (original)
+++ poi/trunk/src/testcases/org/apache/poi/ss/formula/functions/TestDate.java Mon Jul  4 10:15:18 2016
@@ -25,6 +25,7 @@ import org.apache.poi.hssf.usermodel.HSS
 import org.apache.poi.hssf.usermodel.HSSFSheet;
 import org.apache.poi.hssf.usermodel.HSSFWorkbook;
 import org.apache.poi.ss.usermodel.Cell;
+import org.apache.poi.ss.usermodel.CellType;
 import org.apache.poi.ss.usermodel.CellValue;
 
 /**
@@ -39,7 +40,7 @@ public final class TestDate extends Test
         HSSFWorkbook wb = new HSSFWorkbook();
         HSSFSheet sheet = wb.createSheet("new sheet");
         cell11 = sheet.createRow(0).createCell(0);
-        cell11.setCellType(HSSFCell.CELL_TYPE_FORMULA);
+        cell11.setCellType(CellType.FORMULA);
         evaluator = new HSSFFormulaEvaluator(wb);
     }
 
@@ -81,7 +82,7 @@ public final class TestDate extends Test
         cell11.setCellFormula(formulaText);
         evaluator.clearAllCachedResultValues();
         CellValue cv = evaluator.evaluate(cell11);
-        if (cv.getCellType() != Cell.CELL_TYPE_NUMERIC) {
+        if (cv.getCellType() != CellType.NUMERIC) {
             throw new AssertionFailedError("Wrong result type: " + cv.formatAsString());
         }
         double actualValue = cv.getNumberValue();

Modified: poi/trunk/src/testcases/org/apache/poi/ss/formula/functions/TestFind.java
URL: http://svn.apache.org/viewvc/poi/trunk/src/testcases/org/apache/poi/ss/formula/functions/TestFind.java?rev=1751240&r1=1751239&r2=1751240&view=diff
==============================================================================
--- poi/trunk/src/testcases/org/apache/poi/ss/formula/functions/TestFind.java (original)
+++ poi/trunk/src/testcases/org/apache/poi/ss/formula/functions/TestFind.java Mon Jul  4 10:15:18 2016
@@ -24,6 +24,7 @@ import java.io.IOException;
 import org.apache.poi.hssf.usermodel.HSSFCell;
 import org.apache.poi.hssf.usermodel.HSSFFormulaEvaluator;
 import org.apache.poi.hssf.usermodel.HSSFWorkbook;
+import org.apache.poi.ss.usermodel.CellType;
 import org.apache.poi.ss.usermodel.CellValue;
 import org.apache.poi.ss.usermodel.FormulaError;
 import org.junit.Test;
@@ -65,7 +66,7 @@ public final class TestFind {
 		cell.setCellFormula(formulaText);
 		fe.notifyUpdateCell(cell);
 		CellValue result = fe.evaluate(cell);
-		assertEquals(result.getCellType(), HSSFCell.CELL_TYPE_NUMERIC);
+		assertEquals(result.getCellType(), CellType.NUMERIC);
 		assertEquals(expectedResult, result.getNumberValue(), 0.0);
 	}
 
@@ -74,7 +75,7 @@ public final class TestFind {
 		cell.setCellFormula(formulaText);
 		fe.notifyUpdateCell(cell);
 		CellValue result = fe.evaluate(cell);
-		assertEquals(result.getCellType(), HSSFCell.CELL_TYPE_ERROR);
+		assertEquals(result.getCellType(), CellType.ERROR);
 		assertEquals(expectedErrorCode.getCode(), result.getErrorValue());
 	}
 }

Modified: poi/trunk/src/testcases/org/apache/poi/ss/formula/functions/TestFixed.java
URL: http://svn.apache.org/viewvc/poi/trunk/src/testcases/org/apache/poi/ss/formula/functions/TestFixed.java?rev=1751240&r1=1751239&r2=1751240&view=diff
==============================================================================
--- poi/trunk/src/testcases/org/apache/poi/ss/formula/functions/TestFixed.java (original)
+++ poi/trunk/src/testcases/org/apache/poi/ss/formula/functions/TestFixed.java Mon Jul  4 10:15:18 2016
@@ -31,7 +31,7 @@ import org.apache.poi.ss.formula.eval.Er
 import org.apache.poi.ss.formula.eval.NumberEval;
 import org.apache.poi.ss.formula.eval.StringEval;
 import org.apache.poi.ss.formula.eval.ValueEval;
-import org.apache.poi.ss.usermodel.Cell;
+import org.apache.poi.ss.usermodel.CellType;
 import org.apache.poi.ss.usermodel.CellValue;
 import org.apache.poi.ss.usermodel.FormulaError;
 import org.junit.Before;
@@ -48,7 +48,7 @@ public final class TestFixed {
         try {
             HSSFSheet sheet = wb.createSheet("new sheet");
             cell11 = sheet.createRow(0).createCell(0);
-            cell11.setCellType(HSSFCell.CELL_TYPE_FORMULA);
+            cell11.setCellType(CellType.FORMULA);
             evaluator = new HSSFFormulaEvaluator(wb);
         } finally {
             wb.close();
@@ -117,7 +117,7 @@ public final class TestFixed {
         cell11.setCellFormula(formulaText);
         evaluator.clearAllCachedResultValues();
         CellValue cv = evaluator.evaluate(cell11);
-        assertEquals("Wrong result type: " + cv.formatAsString(), Cell.CELL_TYPE_STRING, cv.getCellType());
+        assertEquals("Wrong result type: " + cv.formatAsString(), CellType.STRING, cv.getCellType());
         String actualValue = cv.getStringValue();
         assertEquals(expectedResult, actualValue);
     }
@@ -127,7 +127,7 @@ public final class TestFixed {
         evaluator.clearAllCachedResultValues();
         CellValue cv = evaluator.evaluate(cell11);
         assertTrue("Wrong result type: " + cv.formatAsString(), 
-                cv.getCellType() == Cell.CELL_TYPE_ERROR
+                cv.getCellType() == CellType.ERROR
                 && cv.getErrorValue() == FormulaError.VALUE.getCode());
     }
 }

Modified: poi/trunk/src/testcases/org/apache/poi/ss/formula/functions/TestIndirect.java
URL: http://svn.apache.org/viewvc/poi/trunk/src/testcases/org/apache/poi/ss/formula/functions/TestIndirect.java?rev=1751240&r1=1751239&r2=1751240&view=diff
==============================================================================
--- poi/trunk/src/testcases/org/apache/poi/ss/formula/functions/TestIndirect.java (original)
+++ poi/trunk/src/testcases/org/apache/poi/ss/formula/functions/TestIndirect.java Mon Jul  4 10:15:18 2016
@@ -28,6 +28,7 @@ import org.apache.poi.hssf.usermodel.HSS
 import org.apache.poi.hssf.usermodel.HSSFWorkbook;
 import org.apache.poi.ss.formula.eval.ErrorEval;
 import org.apache.poi.ss.usermodel.Cell;
+import org.apache.poi.ss.usermodel.CellType;
 import org.apache.poi.ss.usermodel.CellValue;
 import org.apache.poi.ss.usermodel.FormulaEvaluator;
 import org.junit.Test;
@@ -182,7 +183,7 @@ public final class TestIndirect {
         fe.clearAllCachedResultValues();
         cell.setCellFormula(formula);
         CellValue cv = fe.evaluate(cell);
-        if (cv.getCellType() != Cell.CELL_TYPE_NUMERIC) {
+        if (cv.getCellType() != CellType.NUMERIC) {
             fail("expected numeric cell type but got " + cv.formatAsString());
         }
         assertEquals(expectedResult, cv.getNumberValue(), 0.0);
@@ -193,7 +194,7 @@ public final class TestIndirect {
         fe.clearAllCachedResultValues();
         cell.setCellFormula(formula);
         CellValue cv = fe.evaluate(cell);
-        if (cv.getCellType() != Cell.CELL_TYPE_ERROR) {
+        if (cv.getCellType() != CellType.ERROR) {
             fail("expected error cell type but got " + cv.formatAsString());
         }
         int expCode = expectedResult.getErrorCode();

Modified: poi/trunk/src/testcases/org/apache/poi/ss/formula/functions/TestIrr.java
URL: http://svn.apache.org/viewvc/poi/trunk/src/testcases/org/apache/poi/ss/formula/functions/TestIrr.java?rev=1751240&r1=1751239&r2=1751240&view=diff
==============================================================================
--- poi/trunk/src/testcases/org/apache/poi/ss/formula/functions/TestIrr.java (original)
+++ poi/trunk/src/testcases/org/apache/poi/ss/formula/functions/TestIrr.java Mon Jul  4 10:15:18 2016
@@ -17,12 +17,18 @@
 
 package org.apache.poi.ss.formula.functions;
 
-import junit.framework.TestCase;
-import junit.framework.AssertionFailedError;
-import org.apache.poi.hssf.usermodel.*;
 import org.apache.poi.hssf.HSSFTestDataSamples;
+import org.apache.poi.hssf.usermodel.HSSFCell;
+import org.apache.poi.hssf.usermodel.HSSFFormulaEvaluator;
+import org.apache.poi.hssf.usermodel.HSSFRow;
+import org.apache.poi.hssf.usermodel.HSSFSheet;
+import org.apache.poi.hssf.usermodel.HSSFWorkbook;
+import org.apache.poi.ss.usermodel.CellType;
 import org.apache.poi.ss.usermodel.CellValue;
 
+import junit.framework.AssertionFailedError;
+import junit.framework.TestCase;
+
 /**
  * Tests for {@link Irr}
  *
@@ -122,7 +128,7 @@ public final class TestIrr extends TestC
     private static void assertFormulaResult(CellValue cv, HSSFCell cell){
         double actualValue = cv.getNumberValue();
         double expectedValue = cell.getNumericCellValue(); // cached formula result calculated by Excel
-        assertEquals("Invalid formula result: " + cv.toString(), HSSFCell.CELL_TYPE_NUMERIC, cv.getCellType());
+        assertEquals("Invalid formula result: " + cv.toString(), CellType.NUMERIC, cv.getCellType());
         assertEquals(expectedValue, actualValue, 1E-4); // should agree within 0.01%
     }
 }

Modified: poi/trunk/src/testcases/org/apache/poi/ss/formula/functions/TestIsBlank.java
URL: http://svn.apache.org/viewvc/poi/trunk/src/testcases/org/apache/poi/ss/formula/functions/TestIsBlank.java?rev=1751240&r1=1751239&r2=1751240&view=diff
==============================================================================
--- poi/trunk/src/testcases/org/apache/poi/ss/formula/functions/TestIsBlank.java (original)
+++ poi/trunk/src/testcases/org/apache/poi/ss/formula/functions/TestIsBlank.java Mon Jul  4 10:15:18 2016
@@ -17,14 +17,15 @@
 
 package org.apache.poi.ss.formula.functions;
 
-import junit.framework.TestCase;
-
 import org.apache.poi.hssf.usermodel.HSSFCell;
 import org.apache.poi.hssf.usermodel.HSSFFormulaEvaluator;
 import org.apache.poi.hssf.usermodel.HSSFRow;
 import org.apache.poi.hssf.usermodel.HSSFSheet;
 import org.apache.poi.hssf.usermodel.HSSFWorkbook;
+import org.apache.poi.ss.usermodel.CellType;
 import org.apache.poi.ss.usermodel.CellValue;
+
+import junit.framework.TestCase;
 /**
  * Tests for Excel function ISBLANK()
  * 
@@ -46,13 +47,13 @@ public final class TestIsBlank extends T
         
         HSSFFormulaEvaluator fe = new HSSFFormulaEvaluator(wb);
         CellValue result = fe.evaluate(cell);
-        assertEquals(HSSFCell.CELL_TYPE_BOOLEAN, result.getCellType());
+        assertEquals(CellType.BOOLEAN, result.getCellType());
         assertEquals(true, result.getBooleanValue());
         
         cell.setCellFormula("isblank(D7:D7)");
         
         result = fe.evaluate(cell);
-        assertEquals(HSSFCell.CELL_TYPE_BOOLEAN, result.getCellType());
+        assertEquals(CellType.BOOLEAN, result.getCellType());
         assertEquals(true, result.getBooleanValue());
    }
 }

Modified: poi/trunk/src/testcases/org/apache/poi/ss/formula/functions/TestLogicalFunction.java
URL: http://svn.apache.org/viewvc/poi/trunk/src/testcases/org/apache/poi/ss/formula/functions/TestLogicalFunction.java?rev=1751240&r1=1751239&r2=1751240&view=diff
==============================================================================
--- poi/trunk/src/testcases/org/apache/poi/ss/formula/functions/TestLogicalFunction.java (original)
+++ poi/trunk/src/testcases/org/apache/poi/ss/formula/functions/TestLogicalFunction.java Mon Jul  4 10:15:18 2016
@@ -19,9 +19,9 @@ package org.apache.poi.ss.formula.functi
 
 import java.io.IOException;
 
-import junit.framework.TestCase;
 import org.apache.poi.hssf.usermodel.HSSFWorkbook;
 import org.apache.poi.ss.usermodel.Cell;
+import org.apache.poi.ss.usermodel.CellType;
 import org.apache.poi.ss.usermodel.CellValue;
 import org.apache.poi.ss.usermodel.FormulaEvaluator;
 import org.apache.poi.ss.usermodel.Row;
@@ -29,6 +29,8 @@ import org.apache.poi.ss.usermodel.Sheet
 import org.apache.poi.ss.usermodel.Workbook;
 import org.apache.poi.ss.util.CellReference;
 
+import junit.framework.TestCase;
+
 /**
  * LogicalFunction unit tests.
  */
@@ -55,11 +57,11 @@ public class TestLogicalFunction extends
         Row row2 = sh.createRow(1);
         row3 = sh.createRow(2);
 
-        row1.createCell(0, Cell.CELL_TYPE_NUMERIC);
-        row1.createCell(1, Cell.CELL_TYPE_NUMERIC);
+        row1.createCell(0, CellType.NUMERIC);
+        row1.createCell(1, CellType.NUMERIC);
 
-        row2.createCell(0, Cell.CELL_TYPE_NUMERIC);
-        row2.createCell(1, Cell.CELL_TYPE_NUMERIC);
+        row2.createCell(0, CellType.NUMERIC);
+        row2.createCell(1, CellType.NUMERIC);
 
         row3.createCell(0);
         row3.createCell(1);

Modified: poi/trunk/src/testcases/org/apache/poi/ss/formula/functions/TestMirr.java
URL: http://svn.apache.org/viewvc/poi/trunk/src/testcases/org/apache/poi/ss/formula/functions/TestMirr.java?rev=1751240&r1=1751239&r2=1751240&view=diff
==============================================================================
--- poi/trunk/src/testcases/org/apache/poi/ss/formula/functions/TestMirr.java (original)
+++ poi/trunk/src/testcases/org/apache/poi/ss/formula/functions/TestMirr.java Mon Jul  4 10:15:18 2016
@@ -17,9 +17,6 @@
 
 package org.apache.poi.ss.formula.functions;
 
-import junit.framework.AssertionFailedError;
-import junit.framework.TestCase;
-
 import org.apache.poi.hssf.HSSFTestDataSamples;
 import org.apache.poi.hssf.usermodel.HSSFCell;
 import org.apache.poi.hssf.usermodel.HSSFFormulaEvaluator;
@@ -28,8 +25,12 @@ import org.apache.poi.hssf.usermodel.HSS
 import org.apache.poi.hssf.usermodel.HSSFWorkbook;
 import org.apache.poi.ss.formula.eval.ErrorEval;
 import org.apache.poi.ss.formula.eval.EvaluationException;
+import org.apache.poi.ss.usermodel.CellType;
 import org.apache.poi.ss.usermodel.CellValue;
 
+import junit.framework.AssertionFailedError;
+import junit.framework.TestCase;
+
 /**
  * Tests for {@link org.apache.poi.ss.formula.functions.Mirr}
  *
@@ -161,7 +162,7 @@ public final class TestMirr extends Test
     private static void assertFormulaResult(CellValue cv, HSSFCell cell) {
         double actualValue = cv.getNumberValue();
         double expectedValue = cell.getNumericCellValue(); // cached formula result calculated by Excel
-        assertEquals("Invalid formula result: " + cv.toString(), HSSFCell.CELL_TYPE_NUMERIC, cv.getCellType());
+        assertEquals("Invalid formula result: " + cv.toString(), CellType.NUMERIC, cv.getCellType());
         assertEquals(expectedValue, actualValue, 1E-8);
     }
 }




---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@poi.apache.org
For additional commands, e-mail: commits-help@poi.apache.org


Mime
View raw message