Sonar fixes

JUnit5 test classes and methods should have default package visibility

git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1885325 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Andreas Beeker 2021-01-10 01:34:16 +00:00
parent a42b47c27c
commit 9c358836b4
119 changed files with 119 additions and 119 deletions

View File

@ -38,7 +38,7 @@ import org.junit.jupiter.api.Test;
* *
* Should be fixed in JDK 12-ea+29 and JDK 13-ea+5 * Should be fixed in JDK 12-ea+29 and JDK 13-ea+5
*/ */
public class TestJDK12 { class TestJDK12 {
@Test @Test
void test() { void test() {
assertDoesNotThrow(() -> { assertDoesNotThrow(() -> {

View File

@ -23,7 +23,7 @@ import org.apache.poi.util.HexDump;
import org.apache.poi.util.HexRead; import org.apache.poi.util.HexRead;
import org.junit.jupiter.api.Test; import org.junit.jupiter.api.Test;
public class TestEscherClientAnchorRecord { class TestEscherClientAnchorRecord {
@Test @Test
void testSerialize() { void testSerialize() {
EscherClientAnchorRecord r = createRecord(); EscherClientAnchorRecord r = createRecord();

View File

@ -23,7 +23,7 @@ import org.apache.poi.util.HexDump;
import org.apache.poi.util.HexRead; import org.apache.poi.util.HexRead;
import org.junit.jupiter.api.Test; import org.junit.jupiter.api.Test;
public class TestEscherClientDataRecord { class TestEscherClientDataRecord {
@Test @Test
void testSerialize() { void testSerialize() {
EscherClientDataRecord r = createRecord(); EscherClientDataRecord r = createRecord();

View File

@ -36,7 +36,7 @@ import org.apache.poi.util.IOUtils;
import org.junit.jupiter.api.BeforeEach; import org.junit.jupiter.api.BeforeEach;
import org.junit.jupiter.api.Test; import org.junit.jupiter.api.Test;
public class TestEscherDump { class TestEscherDump {
private static final String recordData = private static final String recordData =
"H4sIAAAAAAAAAL2UaVCSWxjHX0SBChABLRXM1FxSEzXTzHK7dpVIcMmwxXCP9KaGTaWlGYLrtGmGmYEmYmqF2qIt4ppmjNG+" + "H4sIAAAAAAAAAL2UaVCSWxjHX0SBChABLRXM1FxSEzXTzHK7dpVIcMmwxXCP9KaGTaWlGYLrtGmGmYEmYmqF2qIt4ppmjNG+" +
"2dWulUtOUdq1NHjva8v90HT7eM+Z5znP/M9/zpk5v3mONgAoc5AANBDKeVDW0gQAjZkVCti3mKnpAExpB/m8AKTyEiTCNd2J" + "2dWulUtOUdq1NHjva8v90HT7eM+Z5znP/M9/zpk5v3mONgAoc5AANBDKeVDW0gQAjZkVCti3mKnpAExpB/m8AKTyEiTCNd2J" +

View File

@ -24,7 +24,7 @@ import static org.junit.jupiter.api.Assertions.assertTrue;
import org.junit.jupiter.api.Test; import org.junit.jupiter.api.Test;
public class TestEscherProperty { class TestEscherProperty {
/** /**
* assure that EscherProperty.getName() returns correct name for complex properties * assure that EscherProperty.getName() returns correct name for complex properties
* See Bugzilla 50401 * See Bugzilla 50401

View File

@ -25,7 +25,7 @@ import org.apache.poi.util.HexDump;
import org.apache.poi.util.HexRead; import org.apache.poi.util.HexRead;
import org.junit.jupiter.api.Test; import org.junit.jupiter.api.Test;
public class TestEscherPropertyFactory { class TestEscherPropertyFactory {
@Test @Test
void testCreateProperties() { void testCreateProperties() {
String dataStr = "41 C1 " + // propid, complex ind String dataStr = "41 C1 " + // propid, complex ind

View File

@ -23,7 +23,7 @@ import org.apache.poi.util.HexDump;
import org.apache.poi.util.HexRead; import org.apache.poi.util.HexRead;
import org.junit.jupiter.api.Test; import org.junit.jupiter.api.Test;
public class TestEscherSpRecord { class TestEscherSpRecord {
@Test @Test
void testSerialize() { void testSerialize() {
EscherSpRecord r = createRecord(); EscherSpRecord r = createRecord();

View File

@ -32,7 +32,7 @@ import org.apache.poi.poifs.storage.RawDataUtil;
import org.apache.poi.util.LittleEndianByteArrayInputStream; import org.apache.poi.util.LittleEndianByteArrayInputStream;
import org.junit.jupiter.api.Test; import org.junit.jupiter.api.Test;
public class TestVariantSupport { class TestVariantSupport {
@Test @Test
void test52337() throws Exception { void test52337() throws Exception {
// document summary stream from test1-excel.doc attached to Bugzilla 52337 // document summary stream from test1-excel.doc attached to Bugzilla 52337

View File

@ -51,7 +51,7 @@ import org.junit.jupiter.params.provider.MethodSource;
* in the "data" directory. If you want to ensure HPSF can deal with a certain * in the "data" directory. If you want to ensure HPSF can deal with a certain
* OLE2 file, just add it to the "data" directory and run this test case. * OLE2 file, just add it to the "data" directory and run this test case.
*/ */
public class TestReadAllFiles { class TestReadAllFiles {
private static final POIDataSamples _samples = POIDataSamples.getHPSFInstance(); private static final POIDataSamples _samples = POIDataSamples.getHPSFInstance();
public static Stream<Arguments> files() { public static Stream<Arguments> files() {

View File

@ -39,7 +39,7 @@ import org.junit.jupiter.api.Test;
/** /**
* Tests whether Unicode string can be read from a DocumentSummaryInformation. * Tests whether Unicode string can be read from a DocumentSummaryInformation.
*/ */
public class TestUnicode { class TestUnicode {
static final String POI_FS = "TestUnicode.xls"; static final String POI_FS = "TestUnicode.xls";
static final String[] POI_FILES = { static final String[] POI_FILES = {

View File

@ -79,7 +79,7 @@ import org.junit.jupiter.api.Test;
/** /**
* Tests HPSF's writing functionality * Tests HPSF's writing functionality
*/ */
public class TestWrite { class TestWrite {
private static final POIDataSamples _samples = POIDataSamples.getHPSFInstance(); private static final POIDataSamples _samples = POIDataSamples.getHPSFInstance();
private static final int CODEPAGE_DEFAULT = -1; private static final int CODEPAGE_DEFAULT = -1;

View File

@ -58,7 +58,7 @@ import org.junit.jupiter.api.Test;
* <p>Tests HPSF's high-level writing functionality for the well-known property * <p>Tests HPSF's high-level writing functionality for the well-known property
* set "SummaryInformation" and "DocumentSummaryInformation".</p> * set "SummaryInformation" and "DocumentSummaryInformation".</p>
*/ */
public class TestWriteWellKnown { class TestWriteWellKnown {
private static final String POI_FS = "TestWriteWellKnown.doc"; private static final String POI_FS = "TestWriteWellKnown.doc";

View File

@ -27,7 +27,7 @@ import org.apache.poi.util.NullOutputStream;
import org.apache.poi.util.RecordFormatException; import org.apache.poi.util.RecordFormatException;
import org.junit.jupiter.api.BeforeAll; import org.junit.jupiter.api.BeforeAll;
public class TestBiffDrawingToXml extends BaseTestIteratingXLS { class TestBiffDrawingToXml extends BaseTestIteratingXLS {
@BeforeAll @BeforeAll
public static void setup() { public static void setup() {
EXCLUDED.clear(); EXCLUDED.clear();

View File

@ -29,7 +29,7 @@ import org.apache.poi.util.NullOutputStream;
import org.apache.poi.util.RecordFormatException; import org.apache.poi.util.RecordFormatException;
import org.junit.jupiter.api.BeforeAll; import org.junit.jupiter.api.BeforeAll;
public class TestBiffViewer extends BaseTestIteratingXLS { class TestBiffViewer extends BaseTestIteratingXLS {
@BeforeAll @BeforeAll
public static void setup() { public static void setup() {
EXCLUDED.clear(); EXCLUDED.clear();

View File

@ -27,7 +27,7 @@ import org.apache.poi.util.NullPrintStream;
import org.apache.poi.util.RecordFormatException; import org.apache.poi.util.RecordFormatException;
import org.junit.jupiter.api.BeforeAll; import org.junit.jupiter.api.BeforeAll;
public class TestEFBiffViewer extends BaseTestIteratingXLS { class TestEFBiffViewer extends BaseTestIteratingXLS {
@BeforeAll @BeforeAll
public static void setup() { public static void setup() {
EXCLUDED.clear(); EXCLUDED.clear();

View File

@ -28,7 +28,7 @@ import org.apache.poi.util.NullPrintStream;
import org.apache.poi.util.RecordFormatException; import org.apache.poi.util.RecordFormatException;
import org.junit.jupiter.api.BeforeAll; import org.junit.jupiter.api.BeforeAll;
public class TestFormulaViewer extends BaseTestIteratingXLS { class TestFormulaViewer extends BaseTestIteratingXLS {
@BeforeAll @BeforeAll
public static void setup() { public static void setup() {
EXCLUDED.clear(); EXCLUDED.clear();

View File

@ -31,7 +31,7 @@ import org.junit.jupiter.api.BeforeAll;
import org.junit.jupiter.api.Disabled; import org.junit.jupiter.api.Disabled;
import org.junit.jupiter.api.Test; import org.junit.jupiter.api.Test;
public class TestReSave extends BaseTestIteratingXLS { class TestReSave extends BaseTestIteratingXLS {
@BeforeAll @BeforeAll
public static void setup() { public static void setup() {
EXCLUDED.clear(); EXCLUDED.clear();

View File

@ -25,7 +25,7 @@ import org.apache.poi.util.NullPrintStream;
import org.apache.poi.util.RecordFormatException; import org.apache.poi.util.RecordFormatException;
import org.junit.jupiter.api.BeforeAll; import org.junit.jupiter.api.BeforeAll;
public class TestRecordLister extends BaseTestIteratingXLS { class TestRecordLister extends BaseTestIteratingXLS {
@BeforeAll @BeforeAll
public static void setup() { public static void setup() {
EXCLUDED.clear(); EXCLUDED.clear();

View File

@ -60,7 +60,7 @@ import org.junit.jupiter.params.ParameterizedTest;
import org.junit.jupiter.params.provider.Arguments; import org.junit.jupiter.params.provider.Arguments;
import org.junit.jupiter.params.provider.MethodSource; import org.junit.jupiter.params.provider.MethodSource;
public class TestDrawingAggregate { class TestDrawingAggregate {
/** /**
* information about drawing aggregate in a worksheet * information about drawing aggregate in a worksheet
*/ */

View File

@ -68,7 +68,7 @@ import org.junit.jupiter.api.Test;
* *
* optionally the system setting "poi.deserialize.escher" can be set to {@code true} * optionally the system setting "poi.deserialize.escher" can be set to {@code true}
*/ */
public class TestDrawingShapes { class TestDrawingShapes {
/** /**
* HSSFShape tree bust be built correctly * HSSFShape tree bust be built correctly
* Check file with such records structure: * Check file with such records structure:

View File

@ -40,7 +40,7 @@ import org.apache.poi.hssf.usermodel.HSSFTestHelper;
import org.apache.poi.hssf.usermodel.HSSFWorkbook; import org.apache.poi.hssf.usermodel.HSSFWorkbook;
import org.junit.jupiter.api.Test; import org.junit.jupiter.api.Test;
public class TestEscherRecordFactory { class TestEscherRecordFactory {
private static byte[] toByteArray(List<RecordBase> records) { private static byte[] toByteArray(List<RecordBase> records) {
ByteArrayOutputStream out = new ByteArrayOutputStream(); ByteArrayOutputStream out = new ByteArrayOutputStream();

View File

@ -41,7 +41,7 @@ import org.apache.poi.hssf.usermodel.HSSFWorkbook;
import org.apache.poi.ss.usermodel.ClientAnchor.AnchorType; import org.apache.poi.ss.usermodel.ClientAnchor.AnchorType;
import org.junit.jupiter.api.Test; import org.junit.jupiter.api.Test;
public class TestHSSFAnchor { class TestHSSFAnchor {
@Test @Test
void testDefaultValues(){ void testDefaultValues(){

View File

@ -34,7 +34,7 @@ import org.junit.jupiter.api.Test;
/** /**
* Unit tests for DConRefRecord class. * Unit tests for DConRefRecord class.
*/ */
public class TestDConRefRecord { class TestDConRefRecord {
/** /**
* record of a proper single-byte external 'volume'-style path with multiple parts and a sheet * record of a proper single-byte external 'volume'-style path with multiple parts and a sheet
* name. * name.

View File

@ -26,7 +26,7 @@ import org.apache.poi.hssf.extractor.ExcelExtractor;
import org.apache.poi.hssf.record.crypto.Biff8EncryptionKey; import org.apache.poi.hssf.record.crypto.Biff8EncryptionKey;
import org.junit.jupiter.api.Test; import org.junit.jupiter.api.Test;
public class TestCryptoAPI { class TestCryptoAPI {
final HSSFITestDataProvider ssTests = HSSFITestDataProvider.instance; final HSSFITestDataProvider ssTests = HSSFITestDataProvider.instance;
@Test @Test

View File

@ -29,7 +29,7 @@ import org.junit.jupiter.api.Test;
/** /**
* Tests for the embedded object fetching support in HSSF * Tests for the embedded object fetching support in HSSF
*/ */
public class TestEmbeddedObjects { class TestEmbeddedObjects {
@Test @Test
void testReadExistingObject() throws IOException { void testReadExistingObject() throws IOException {
try (HSSFWorkbook wb = HSSFTestDataSamples.openSampleWorkbook("drawings.xls")) { try (HSSFWorkbook wb = HSSFTestDataSamples.openSampleWorkbook("drawings.xls")) {

View File

@ -27,7 +27,7 @@ import org.apache.poi.hssf.HSSFTestDataSamples;
import org.apache.poi.ss.usermodel.CellType; import org.apache.poi.ss.usermodel.CellType;
import org.junit.jupiter.api.Test; import org.junit.jupiter.api.Test;
public class TestExternalReferenceChange { class TestExternalReferenceChange {
private static final String MAIN_WORKBOOK_FILENAME = "52575_main.xls"; private static final String MAIN_WORKBOOK_FILENAME = "52575_main.xls";
private static final String SOURCE_DUMMY_WORKBOOK_FILENAME = "source_dummy.xls"; private static final String SOURCE_DUMMY_WORKBOOK_FILENAME = "source_dummy.xls";

View File

@ -21,7 +21,7 @@ package org.apache.poi.hssf.usermodel;
import org.apache.poi.hssf.usermodel.helpers.HSSFColumnShifter; import org.apache.poi.hssf.usermodel.helpers.HSSFColumnShifter;
import org.apache.poi.ss.usermodel.BaseTestColumnShifting; import org.apache.poi.ss.usermodel.BaseTestColumnShifting;
public class TestHSSFColumnShifting extends BaseTestColumnShifting { class TestHSSFColumnShifting extends BaseTestColumnShifting {
public TestHSSFColumnShifting() { public TestHSSFColumnShifting() {
super(); super();
wb = new HSSFWorkbook(); wb = new HSSFWorkbook();

View File

@ -36,7 +36,7 @@ import org.junit.jupiter.api.Test;
/** /**
* Class TestHSSFDateUtil * Class TestHSSFDateUtil
*/ */
public class TestHSSFDateUtil { class TestHSSFDateUtil {
static TimeZone userTimeZone; static TimeZone userTimeZone;

View File

@ -29,7 +29,7 @@ import org.apache.poi.ss.usermodel.BaseTestXEvaluationSheet;
import org.apache.poi.ss.usermodel.Sheet; import org.apache.poi.ss.usermodel.Sheet;
import org.junit.jupiter.api.Test; import org.junit.jupiter.api.Test;
public class TestHSSFEvaluationSheet extends BaseTestXEvaluationSheet { class TestHSSFEvaluationSheet extends BaseTestXEvaluationSheet {
@Override @Override
protected Map.Entry<Sheet, EvaluationSheet> getInstance() { protected Map.Entry<Sheet, EvaluationSheet> getInstance() {
HSSFSheet sheet = new HSSFWorkbook().createSheet(); HSSFSheet sheet = new HSSFWorkbook().createSheet();

View File

@ -24,7 +24,7 @@ import org.apache.poi.hssf.HSSFTestDataSamples;
import org.apache.poi.ss.usermodel.BaseTestRangeCopier; import org.apache.poi.ss.usermodel.BaseTestRangeCopier;
import org.junit.jupiter.api.BeforeEach; import org.junit.jupiter.api.BeforeEach;
public class TestHSSFRangeCopier extends BaseTestRangeCopier { class TestHSSFRangeCopier extends BaseTestRangeCopier {
public TestHSSFRangeCopier() { public TestHSSFRangeCopier() {
super(); super();

View File

@ -27,7 +27,7 @@ import org.apache.poi.ss.usermodel.Workbook;
import org.junit.jupiter.api.Disabled; import org.junit.jupiter.api.Disabled;
import org.junit.jupiter.api.Test; import org.junit.jupiter.api.Test;
public class TestHSSFSheetShiftColumns extends BaseTestSheetShiftColumns { class TestHSSFSheetShiftColumns extends BaseTestSheetShiftColumns {
public TestHSSFSheetShiftColumns() { public TestHSSFSheetShiftColumns() {
super(); super();
workbook = new HSSFWorkbook(); workbook = new HSSFWorkbook();

View File

@ -34,7 +34,7 @@ import org.junit.jupiter.api.Test;
/** /**
* Old-style setting of POIFS properties doesn't work with POI 3.0.2 * Old-style setting of POIFS properties doesn't work with POI 3.0.2
*/ */
public class TestPOIFSProperties { class TestPOIFSProperties {
private static final String title = "Testing POIFS properties"; private static final String title = "Testing POIFS properties";
@Test @Test

View File

@ -27,7 +27,7 @@ import org.apache.poi.hssf.HSSFTestDataSamples;
import org.apache.poi.hssf.record.EscherAggregate; import org.apache.poi.hssf.record.EscherAggregate;
import org.junit.jupiter.api.Test; import org.junit.jupiter.api.Test;
public class TestPatriarch { class TestPatriarch {
@Test @Test
void testGetPatriarch(){ void testGetPatriarch(){
HSSFWorkbook wb = new HSSFWorkbook(); HSSFWorkbook wb = new HSSFWorkbook();

View File

@ -31,7 +31,7 @@ import org.apache.poi.hssf.HSSFTestDataSamples;
import org.apache.poi.hssf.record.ObjRecord; import org.apache.poi.hssf.record.ObjRecord;
import org.junit.jupiter.api.Test; import org.junit.jupiter.api.Test;
public class TestPolygon { class TestPolygon {
@Test @Test
void testResultEqualsToAbstractShape() throws IOException { void testResultEqualsToAbstractShape() throws IOException {
HSSFWorkbook wb = new HSSFWorkbook(); HSSFWorkbook wb = new HSSFWorkbook();

View File

@ -30,7 +30,7 @@ import org.apache.poi.hssf.HSSFTestDataSamples;
import org.apache.poi.hssf.record.EscherAggregate; import org.apache.poi.hssf.record.EscherAggregate;
import org.junit.jupiter.api.Test; import org.junit.jupiter.api.Test;
public class TestShapeGroup { class TestShapeGroup {
@Test @Test
void testSetGetCoordinates() throws IOException { void testSetGetCoordinates() throws IOException {

View File

@ -32,7 +32,7 @@ import org.junit.jupiter.api.Test;
* @author Evgeniy Berlog * @author Evgeniy Berlog
* @date 25.06.12 * @date 25.06.12
*/ */
public class TestText { class TestText {
@Test @Test
void testResultEqualsToNonExistingAbstractShape() throws IOException { void testResultEqualsToNonExistingAbstractShape() throws IOException {

View File

@ -23,7 +23,7 @@ import static org.junit.jupiter.api.Assertions.assertThrows;
import org.apache.poi.EncryptedDocumentException; import org.apache.poi.EncryptedDocumentException;
import org.junit.jupiter.api.Test; import org.junit.jupiter.api.Test;
public class TestCipherAlgorithm { class TestCipherAlgorithm {
@Test @Test
void validInputs() { void validInputs() {
assertEquals(128, CipherAlgorithm.aes128.defaultKeySize); assertEquals(128, CipherAlgorithm.aes128.defaultKeySize);

View File

@ -36,7 +36,7 @@ import org.apache.poi.util.HexRead;
import org.junit.jupiter.api.Disabled; import org.junit.jupiter.api.Disabled;
import org.junit.jupiter.api.Test; import org.junit.jupiter.api.Test;
public class TestXorEncryption { class TestXorEncryption {
private static final HSSFTestDataSamples samples = new HSSFTestDataSamples(); private static final HSSFTestDataSamples samples = new HSSFTestDataSamples();

View File

@ -30,7 +30,7 @@ import org.apache.poi.poifs.crypt.EncryptionInfo;
import org.apache.poi.poifs.crypt.EncryptionMode; import org.apache.poi.poifs.crypt.EncryptionMode;
import org.junit.jupiter.api.Test; import org.junit.jupiter.api.Test;
public class TestBinaryRC4 { class TestBinaryRC4 {
@Test @Test
void createKeyDigest() { void createKeyDigest() {
byte[] docIdData = readFromString("17 F6 D1 6B 09 B1 5F 7B 4C 9D 03 B4 81 B5 B4 4A"); byte[] docIdData = readFromString("17 F6 D1 6B 09 B1 5F 7B 4C 9D 03 B4 81 B5 B4 4A");

View File

@ -37,7 +37,7 @@ import org.junit.jupiter.api.Test;
/** /**
* Class to test POIFSDocument functionality * Class to test POIFSDocument functionality
*/ */
public class TestDocument { class TestDocument {
/** /**
* Integration test -- really about all we can do * Integration test -- really about all we can do

View File

@ -32,7 +32,7 @@ import java.util.List;
import org.junit.jupiter.api.Test; import org.junit.jupiter.api.Test;
public class TestEntryUtils { class TestEntryUtils {
private static final byte[] dataSmallA = new byte[] { 12, 42, 11, -12, -121 }; private static final byte[] dataSmallA = new byte[] { 12, 42, 11, -12, -121 };
private static final byte[] dataSmallB = new byte[] { 11, 73, 21, -92, -103 }; private static final byte[] dataSmallB = new byte[] { 11, 73, 21, -92, -103 };

View File

@ -39,7 +39,7 @@ import org.apache.poi.POIDataSamples;
import org.apache.poi.util.TempFile; import org.apache.poi.util.TempFile;
import org.junit.jupiter.api.Test; import org.junit.jupiter.api.Test;
public class TestFileMagic { class TestFileMagic {
@Test @Test
void testFileMagic() { void testFileMagic() {
assertEquals(FileMagic.XML, FileMagic.valueOf("XML")); assertEquals(FileMagic.XML, FileMagic.valueOf("XML"));

View File

@ -33,7 +33,7 @@ import org.junit.jupiter.api.Test;
* formats. See also {@link TestOfficeXMLException} for OOXML * formats. See also {@link TestOfficeXMLException} for OOXML
* checks * checks
*/ */
public class TestNotOLE2Exception { class TestNotOLE2Exception {
private static InputStream openXLSSampleStream(String sampleFileName) { private static InputStream openXLSSampleStream(String sampleFileName) {
return HSSFTestDataSamples.openSampleFileStream(sampleFileName); return HSSFTestDataSamples.openSampleFileStream(sampleFileName);
} }

View File

@ -35,7 +35,7 @@ import org.junit.jupiter.api.Test;
* Class to test that POIFS complains when given an Office 2003 XML * Class to test that POIFS complains when given an Office 2003 XML
* of Office Open XML (OOXML, 2007+) document * of Office Open XML (OOXML, 2007+) document
*/ */
public class TestOfficeXMLException { class TestOfficeXMLException {
private static InputStream openSampleStream(String sampleFileName) { private static InputStream openSampleStream(String sampleFileName) {
return HSSFTestDataSamples.openSampleFileStream(sampleFileName); return HSSFTestDataSamples.openSampleFileStream(sampleFileName);

View File

@ -36,7 +36,7 @@ import org.apache.poi.util.IOUtils;
import org.apache.poi.util.RecordFormatException; import org.apache.poi.util.RecordFormatException;
import org.junit.jupiter.api.Test; import org.junit.jupiter.api.Test;
public class TestOle10Native { class TestOle10Native {
private static final POIDataSamples dataSamples = POIDataSamples.getPOIFSInstance(); private static final POIDataSamples dataSamples = POIDataSamples.getPOIFSInstance();
@Test @Test

View File

@ -37,7 +37,7 @@ import java.util.Collections;
import java.util.HashMap; import java.util.HashMap;
import java.util.Map; import java.util.Map;
public class TestVBAMacroReader { class TestVBAMacroReader {
private static final Map<POIDataSamples, String> expectedMacroContents; private static final Map<POIDataSamples, String> expectedMacroContents;
private static String readVBA(POIDataSamples poiDataSamples) { private static String readVBA(POIDataSamples poiDataSamples) {

View File

@ -40,7 +40,7 @@ import org.junit.jupiter.api.Test;
/** /**
* Tests for the datasource implementations * Tests for the datasource implementations
*/ */
public class TestDataSource { class TestDataSource {
private static final POIDataSamples data = POIDataSamples.getPOIFSInstance(); private static final POIDataSamples data = POIDataSamples.getPOIFSInstance();
@Test @Test

View File

@ -27,7 +27,7 @@ import org.junit.jupiter.api.Test;
* *
* @author Yegor Kozlov * @author Yegor Kozlov
*/ */
public class TestFormulaParser { class TestFormulaParser {
@Test @Test
void testParse(){ void testParse(){

View File

@ -30,7 +30,7 @@ import java.util.Enumeration;
import org.junit.jupiter.api.Disabled; import org.junit.jupiter.api.Disabled;
import org.junit.jupiter.api.Test; import org.junit.jupiter.api.Test;
public class TestPresetGeometries { class TestPresetGeometries {
@Test @Test
void testRead(){ void testRead(){
PresetGeometries shapes = PresetGeometries.getInstance(); PresetGeometries shapes = PresetGeometries.getInstance();

View File

@ -43,7 +43,7 @@ import org.junit.jupiter.api.Assertions;
import org.junit.jupiter.api.BeforeAll; import org.junit.jupiter.api.BeforeAll;
import org.junit.jupiter.api.Test; import org.junit.jupiter.api.Test;
public class TestCellFormat { class TestCellFormat {
private static TimeZone userTimeZone; private static TimeZone userTimeZone;

View File

@ -21,7 +21,7 @@ import static org.junit.jupiter.api.Assertions.assertTrue;
import org.junit.jupiter.api.Test; import org.junit.jupiter.api.Test;
public class TestCellFormatCondition { class TestCellFormatCondition {
@Test @Test
void testSVConditions() { void testSVConditions() {
CellFormatCondition lt = CellFormatCondition.getInstance("<", "1.5"); CellFormatCondition lt = CellFormatCondition.getInstance("<", "1.5");

View File

@ -22,7 +22,7 @@ import java.awt.Color;
import org.junit.jupiter.api.Test; import org.junit.jupiter.api.Test;
public class TestCellFormatResult { class TestCellFormatResult {
@Test @Test
void testNullTextRaisesException() { void testNullTextRaisesException() {

View File

@ -26,7 +26,7 @@ import org.junit.jupiter.api.Test;
/** /**
* Tests {@link org.apache.poi.ss.formula.CellCacheEntry}. * Tests {@link org.apache.poi.ss.formula.CellCacheEntry}.
*/ */
public class TestCellCacheEntry { class TestCellCacheEntry {
@Test @Test
void testBasic() { void testBasic() {

View File

@ -59,7 +59,7 @@ import org.junit.jupiter.api.Test;
* values are used. Also checks that changing cell values causes the correct (minimal) set of * values are used. Also checks that changing cell values causes the correct (minimal) set of
* dependent cached values to be cleared. * dependent cached values to be cleared.
*/ */
public class TestEvaluationCache { class TestEvaluationCache {
private static final class FormulaCellCacheEntryComparer implements Comparator<ICacheEntry> { private static final class FormulaCellCacheEntryComparer implements Comparator<ICacheEntry> {

View File

@ -43,7 +43,7 @@ import org.junit.jupiter.api.Test;
import org.junit.jupiter.api.TestMethodOrder; import org.junit.jupiter.api.TestMethodOrder;
@TestMethodOrder(MethodOrderer.MethodName.class) @TestMethodOrder(MethodOrderer.MethodName.class)
public class TestFunctionRegistry { class TestFunctionRegistry {
HSSFWorkbook wb; HSSFWorkbook wb;
HSSFSheet sheet; HSSFSheet sheet;

View File

@ -27,7 +27,7 @@ import org.apache.poi.ss.formula.PlainCellCache.Loc;
import org.apache.poi.ss.formula.eval.NumberEval; import org.apache.poi.ss.formula.eval.NumberEval;
import org.junit.jupiter.api.Test; import org.junit.jupiter.api.Test;
public class TestPlainCellCache { class TestPlainCellCache {
@Test @Test
void testLoc(){ void testLoc(){

View File

@ -57,7 +57,7 @@ import org.junit.jupiter.api.Test;
* *
* @author Josh Micich * @author Josh Micich
*/ */
public class TestWorkbookEvaluator { class TestWorkbookEvaluator {
private static final double EPSILON = 0.0000001; private static final double EPSILON = 0.0000001;

View File

@ -33,7 +33,7 @@ import org.junit.jupiter.api.Test;
/** /**
* Testcase for 'Analysis Toolpak' function IFERROR() * Testcase for 'Analysis Toolpak' function IFERROR()
*/ */
public class TestIfError { class TestIfError {
/** /**
* =IFERROR(210/35,\"Error in calculation\")" Divides 210 by 35 and returns 6.0 * =IFERROR(210/35,\"Error in calculation\")" Divides 210 by 35 and returns 6.0

View File

@ -29,7 +29,7 @@ import org.junit.jupiter.api.Test;
/** /**
* Testcase for 'Analysis Toolpak' function MROUND() * Testcase for 'Analysis Toolpak' function MROUND()
*/ */
public class TestMRound { class TestMRound {
/** /**
=MROUND(10, 3) Rounds 10 to a nearest multiple of 3 (9) =MROUND(10, 3) Rounds 10 to a nearest multiple of 3 (9)

View File

@ -33,7 +33,7 @@ import org.apache.poi.ss.formula.eval.StringEval;
import org.apache.poi.ss.formula.eval.ValueEval; import org.apache.poi.ss.formula.eval.ValueEval;
import org.junit.jupiter.api.Test; import org.junit.jupiter.api.Test;
public class TestNetworkdaysFunction { class TestNetworkdaysFunction {
private static final String STARTING_DATE = "2008/10/01"; private static final String STARTING_DATE = "2008/10/01";
private static final String END_DATE = "2009/03/01"; private static final String END_DATE = "2009/03/01";

View File

@ -31,7 +31,7 @@ import org.junit.jupiter.api.Test;
/** /**
* Testcase for Excel function PERCENTILE() * Testcase for Excel function PERCENTILE()
*/ */
public class TestPercentile { class TestPercentile {
private static ValueEval invokePercentile(ValueEval[] args, ValueEval percentile) { private static ValueEval invokePercentile(ValueEval[] args, ValueEval percentile) {
AreaEval aeA = EvalFactory.createAreaEval("A1:A" + args.length, args); AreaEval aeA = EvalFactory.createAreaEval("A1:A" + args.length, args);

View File

@ -33,7 +33,7 @@ import org.junit.jupiter.api.Test;
/** /**
* Testcase for 'Analysis Toolpak' function RANDBETWEEN() * Testcase for 'Analysis Toolpak' function RANDBETWEEN()
*/ */
public class TestRandBetween { class TestRandBetween {
private FormulaEvaluator evaluator; private FormulaEvaluator evaluator;
private Cell bottomValueCell; private Cell bottomValueCell;

View File

@ -27,7 +27,7 @@ import org.apache.poi.ss.usermodel.DateUtil;
import org.apache.poi.util.LocaleUtil; import org.apache.poi.util.LocaleUtil;
import org.junit.jupiter.api.Test; import org.junit.jupiter.api.Test;
public class TestWorkdayCalculator { class TestWorkdayCalculator {
@Test @Test
void testCalculateWorkdaysShouldReturnJustWeekdaysWhenNoWeekend() { void testCalculateWorkdaysShouldReturnJustWeekdaysWhenNoWeekend() {

View File

@ -38,7 +38,7 @@ import org.apache.poi.ss.usermodel.DateUtil;
import org.apache.poi.util.LocaleUtil; import org.apache.poi.util.LocaleUtil;
import org.junit.jupiter.api.Test; import org.junit.jupiter.api.Test;
public class TestWorkdayFunction { class TestWorkdayFunction {
private static final String STARTING_DATE = "2008/10/01"; private static final String STARTING_DATE = "2008/10/01";
private static final String FIRST_HOLIDAY = "2008/11/26"; private static final String FIRST_HOLIDAY = "2008/11/26";

View File

@ -24,7 +24,7 @@ import org.junit.jupiter.params.provider.Arguments;
/** /**
* Tests boolean functions as loaded from a test data spreadsheet.<p> * Tests boolean functions as loaded from a test data spreadsheet.<p>
*/ */
public class TestBooleanFunctionsFromSpreadsheet extends BaseTestFunctionsFromSpreadsheet { class TestBooleanFunctionsFromSpreadsheet extends BaseTestFunctionsFromSpreadsheet {
public static Stream<Arguments> data() throws Exception { public static Stream<Arguments> data() throws Exception {
return data(TestBooleanFunctionsFromSpreadsheet.class, "BooleanFunctionsTestCaseData.xls"); return data(TestBooleanFunctionsFromSpreadsheet.class, "BooleanFunctionsTestCaseData.xls");
} }

View File

@ -28,7 +28,7 @@ import org.junit.jupiter.api.Test;
* *
* @author cedric dot walter @ gmail dot com * @author cedric dot walter @ gmail dot com
*/ */
public class TestCode { class TestCode {
private static ValueEval invokeValue(String number1) { private static ValueEval invokeValue(String number1) {
ValueEval[] args = new ValueEval[]{new StringEval(number1),}; ValueEval[] args = new ValueEval[]{new StringEval(number1),};
return new Code().evaluate(args, -1, -1); return new Code().evaluate(args, -1, -1);

View File

@ -24,7 +24,7 @@ import org.junit.jupiter.params.provider.Arguments;
/** /**
* Tests CODE() as loaded from a test data spreadsheet.<p> * Tests CODE() as loaded from a test data spreadsheet.<p>
*/ */
public class TestCodeFunctionsFromSpreadsheet extends BaseTestFunctionsFromSpreadsheet { class TestCodeFunctionsFromSpreadsheet extends BaseTestFunctionsFromSpreadsheet {
public static Stream<Arguments> data() throws Exception { public static Stream<Arguments> data() throws Exception {
return data(TestCodeFunctionsFromSpreadsheet.class, "CodeFunctionTestCaseData.xls"); return data(TestCodeFunctionsFromSpreadsheet.class, "CodeFunctionTestCaseData.xls");
} }

View File

@ -28,7 +28,7 @@ import org.junit.jupiter.api.Test;
* *
* @author cedric dot walter @ gmail dot com * @author cedric dot walter @ gmail dot com
*/ */
public class TestComplex { class TestComplex {
private static ValueEval invokeValue(String real_num, String i_num, String suffix) { private static ValueEval invokeValue(String real_num, String i_num, String suffix) {
ValueEval[] args = new ValueEval[]{new StringEval(real_num), new StringEval(i_num), new StringEval(suffix)}; ValueEval[] args = new ValueEval[]{new StringEval(real_num), new StringEval(i_num), new StringEval(suffix)};
return new Complex().evaluate(args, -1, -1); return new Complex().evaluate(args, -1, -1);

View File

@ -24,7 +24,7 @@ import org.junit.jupiter.params.provider.Arguments;
/** /**
* Tests COMPLEX() as loaded from a test data spreadsheet.<p> * Tests COMPLEX() as loaded from a test data spreadsheet.<p>
*/ */
public class TestComplexFunctionsFromSpreadsheet extends BaseTestFunctionsFromSpreadsheet { class TestComplexFunctionsFromSpreadsheet extends BaseTestFunctionsFromSpreadsheet {
public static Stream<Arguments> data() throws Exception { public static Stream<Arguments> data() throws Exception {
return data(TestComplexFunctionsFromSpreadsheet.class, "ComplexFunctionTestCaseData.xls"); return data(TestComplexFunctionsFromSpreadsheet.class, "ComplexFunctionTestCaseData.xls");
} }

View File

@ -23,7 +23,7 @@ import org.junit.jupiter.params.provider.Arguments;
/** /**
* Tests DGET() as loaded from a test data spreadsheet. * Tests DGET() as loaded from a test data spreadsheet.
*/ */
public class TestDGetFunctionsFromSpreadsheet extends BaseTestFunctionsFromSpreadsheet { class TestDGetFunctionsFromSpreadsheet extends BaseTestFunctionsFromSpreadsheet {
public static Stream<Arguments> data() throws Exception { public static Stream<Arguments> data() throws Exception {
return data(TestDGetFunctionsFromSpreadsheet.class, "DGet.xls"); return data(TestDGetFunctionsFromSpreadsheet.class, "DGet.xls");
} }

View File

@ -23,7 +23,7 @@ import org.junit.jupiter.params.provider.Arguments;
/** /**
* Tests D*() functions as loaded from a test data spreadsheet. * Tests D*() functions as loaded from a test data spreadsheet.
*/ */
public class TestDStarFunctionsFromSpreadsheet extends BaseTestFunctionsFromSpreadsheet { class TestDStarFunctionsFromSpreadsheet extends BaseTestFunctionsFromSpreadsheet {
public static Stream<Arguments> data() throws Exception { public static Stream<Arguments> data() throws Exception {
return data(TestDStarFunctionsFromSpreadsheet.class, "DStar.xls"); return data(TestDStarFunctionsFromSpreadsheet.class, "DStar.xls");
} }

View File

@ -21,7 +21,7 @@ import java.util.stream.Stream;
import org.junit.jupiter.params.provider.Arguments; import org.junit.jupiter.params.provider.Arguments;
public class TestDateTimeToNumberFromSpreadsheet extends BaseTestFunctionsFromSpreadsheet { class TestDateTimeToNumberFromSpreadsheet extends BaseTestFunctionsFromSpreadsheet {
public static Stream<Arguments> data() throws Exception { public static Stream<Arguments> data() throws Exception {
return data(TestDateTimeToNumberFromSpreadsheet.class, "DateTimeToNumberTestCases.xls"); return data(TestDateTimeToNumberFromSpreadsheet.class, "DateTimeToNumberTestCases.xls");
} }

View File

@ -23,7 +23,7 @@ import org.junit.jupiter.params.provider.Arguments;
/** /**
* Tests DELTA() as loaded from a test data spreadsheet.<p> * Tests DELTA() as loaded from a test data spreadsheet.<p>
*/ */
public class TestDeltaFunctionsFromSpreadsheet extends BaseTestFunctionsFromSpreadsheet { class TestDeltaFunctionsFromSpreadsheet extends BaseTestFunctionsFromSpreadsheet {
public static Stream<Arguments> data() throws Exception { public static Stream<Arguments> data() throws Exception {
return data(TestDeltaFunctionsFromSpreadsheet.class, "DeltaFunctionTestCaseData.xls"); return data(TestDeltaFunctionsFromSpreadsheet.class, "DeltaFunctionTestCaseData.xls");
} }

View File

@ -32,7 +32,7 @@ import org.apache.poi.ss.usermodel.FormulaError;
import org.apache.poi.util.LocaleUtil; import org.apache.poi.util.LocaleUtil;
import org.junit.jupiter.api.Test; import org.junit.jupiter.api.Test;
public class TestEDate { class TestEDate {
@Test @Test
void testEDateProperValues() { void testEDateProperValues() {

View File

@ -34,7 +34,7 @@ import org.apache.poi.ss.usermodel.FormulaError;
import org.apache.poi.util.LocaleUtil; import org.apache.poi.util.LocaleUtil;
import org.junit.jupiter.api.Test; import org.junit.jupiter.api.Test;
public class TestEOMonth { class TestEOMonth {
private static final double BAD_DATE = -1.0; private static final double BAD_DATE = -1.0;

View File

@ -24,7 +24,7 @@ import org.junit.jupiter.params.provider.Arguments;
/** /**
* Tests FactDouble() as loaded from a test data spreadsheet.<p> * Tests FactDouble() as loaded from a test data spreadsheet.<p>
*/ */
public class TestFactDoubleFunctionsFromSpreadsheet extends BaseTestFunctionsFromSpreadsheet { class TestFactDoubleFunctionsFromSpreadsheet extends BaseTestFunctionsFromSpreadsheet {
public static Stream<Arguments> data() throws Exception { public static Stream<Arguments> data() throws Exception {
return data(TestFactDoubleFunctionsFromSpreadsheet.class, "FactDoubleFunctionTestCaseData.xls"); return data(TestFactDoubleFunctionsFromSpreadsheet.class, "FactDoubleFunctionTestCaseData.xls");
} }

View File

@ -27,7 +27,7 @@ import org.junit.jupiter.api.Test;
* @author Amol S. Deshmukh &lt; amolweb at ya hoo dot com &gt; * @author Amol S. Deshmukh &lt; amolweb at ya hoo dot com &gt;
* *
*/ */
public class TestFinanceLib extends BaseTestNumeric { class TestFinanceLib extends BaseTestNumeric {
@Test @Test
void testFv() { void testFv() {

View File

@ -24,7 +24,7 @@ import org.junit.jupiter.params.provider.Arguments;
/** /**
* Tests FIXED() as loaded from a test data spreadsheet. * Tests FIXED() as loaded from a test data spreadsheet.
*/ */
public class TestFixedFunctionsFromSpreadsheet extends BaseTestFunctionsFromSpreadsheet { class TestFixedFunctionsFromSpreadsheet extends BaseTestFunctionsFromSpreadsheet {
public static Stream<Arguments> data() throws Exception { public static Stream<Arguments> data() throws Exception {
return data(TestFixedFunctionsFromSpreadsheet.class, "57003-FixedFunctionTestCaseData.xls"); return data(TestFixedFunctionsFromSpreadsheet.class, "57003-FixedFunctionTestCaseData.xls");
} }

View File

@ -35,7 +35,7 @@ import org.junit.jupiter.api.Test;
* *
* @author Yegor Kozlov * @author Yegor Kozlov
*/ */
public class TestFrequency { class TestFrequency {
@Test @Test
void testHistogram() { void testHistogram() {

View File

@ -39,7 +39,7 @@ import org.junit.jupiter.api.Test;
* Remarks: * Remarks:
* Actually, 5. is not true. If an error is encountered before a 0 value, the error is returned. * Actually, 5. is not true. If an error is encountered before a 0 value, the error is returned.
*/ */
public class TestGeomean { class TestGeomean {
@Test @Test
void acceptanceTest() { void acceptanceTest() {
Function geomean = getInstance(); Function geomean = getInstance();

View File

@ -24,7 +24,7 @@ import org.junit.jupiter.params.provider.Arguments;
/** /**
* Tests IF() as loaded from a test data spreadsheet.<p> * Tests IF() as loaded from a test data spreadsheet.<p>
*/ */
public class TestIFFunctionFromSpreadsheet extends BaseTestFunctionsFromSpreadsheet { class TestIFFunctionFromSpreadsheet extends BaseTestFunctionsFromSpreadsheet {
public static Stream<Arguments> data() throws Exception { public static Stream<Arguments> data() throws Exception {
return data(TestIFFunctionFromSpreadsheet.class, "IfFunctionTestCaseData.xls"); return data(TestIFFunctionFromSpreadsheet.class, "IfFunctionTestCaseData.xls");
} }

View File

@ -24,7 +24,7 @@ import org.junit.jupiter.params.provider.Arguments;
/** /**
* Tests ImReal() as loaded from a test data spreadsheet.<p> * Tests ImReal() as loaded from a test data spreadsheet.<p>
*/ */
public class TestImRealFunctionsFromSpreadsheet extends BaseTestFunctionsFromSpreadsheet { class TestImRealFunctionsFromSpreadsheet extends BaseTestFunctionsFromSpreadsheet {
public static Stream<Arguments> data() throws Exception { public static Stream<Arguments> data() throws Exception {
return data(TestImRealFunctionsFromSpreadsheet.class, "ImRealFunctionTestCaseData.xls"); return data(TestImRealFunctionsFromSpreadsheet.class, "ImRealFunctionTestCaseData.xls");
} }

View File

@ -24,7 +24,7 @@ import org.junit.jupiter.params.provider.Arguments;
/** /**
* Tests Imaginary() as loaded from a test data spreadsheet.<p> * Tests Imaginary() as loaded from a test data spreadsheet.<p>
*/ */
public class TestImaginaryFunctionsFromSpreadsheet extends BaseTestFunctionsFromSpreadsheet { class TestImaginaryFunctionsFromSpreadsheet extends BaseTestFunctionsFromSpreadsheet {
public static Stream<Arguments> data() throws Exception { public static Stream<Arguments> data() throws Exception {
return data(TestImaginaryFunctionsFromSpreadsheet.class, "ImaginaryFunctionTestCaseData.xls"); return data(TestImaginaryFunctionsFromSpreadsheet.class, "ImaginaryFunctionTestCaseData.xls");
} }

View File

@ -32,7 +32,7 @@ import org.junit.jupiter.api.Test;
* @author Brendan Nolan * @author Brendan Nolan
* *
*/ */
public class TestLeftRight { class TestLeftRight {
private static final NumberEval NEGATIVE_OPERAND = new NumberEval(-1.0); private static final NumberEval NEGATIVE_OPERAND = new NumberEval(-1.0);
private static final StringEval ANY_STRING_VALUE = new StringEval("ANYSTRINGVALUE"); private static final StringEval ANY_STRING_VALUE = new StringEval("ANYSTRINGVALUE");

View File

@ -37,7 +37,7 @@ import org.junit.jupiter.api.Test;
/** /**
* LogicalFunction unit tests. * LogicalFunction unit tests.
*/ */
public class TestLogicalFunction { class TestLogicalFunction {
private FormulaEvaluator evaluator; private FormulaEvaluator evaluator;
private Row row3; private Row row3;

View File

@ -24,7 +24,7 @@ import org.junit.jupiter.params.provider.Arguments;
/** /**
* Tests for logical ISxxx functions as loaded from a test data spreadsheet.<p> * Tests for logical ISxxx functions as loaded from a test data spreadsheet.<p>
*/ */
public class TestLogicalFunctionsFromSpreadsheet extends BaseTestFunctionsFromSpreadsheet { class TestLogicalFunctionsFromSpreadsheet extends BaseTestFunctionsFromSpreadsheet {
public static Stream<Arguments> data() throws Exception { public static Stream<Arguments> data() throws Exception {
return data(TestLogicalFunctionsFromSpreadsheet.class, "LogicalFunctionsTestCaseData.xls"); return data(TestLogicalFunctionsFromSpreadsheet.class, "LogicalFunctionsTestCaseData.xls");
} }

View File

@ -27,7 +27,7 @@ import org.apache.poi.ss.formula.eval.NumberEval;
import org.apache.poi.ss.formula.eval.ValueEval; import org.apache.poi.ss.formula.eval.ValueEval;
import org.junit.jupiter.api.Test; import org.junit.jupiter.api.Test;
public class TestMultiOperandNumericFunction { class TestMultiOperandNumericFunction {
@Test @Test
void testSettings() { void testSettings() {

View File

@ -29,7 +29,7 @@ import org.junit.jupiter.api.Test;
* Tests for Excel function POISSON(x,mean,cumulative) * Tests for Excel function POISSON(x,mean,cumulative)
* @author Kalpesh Parmar * @author Kalpesh Parmar
*/ */
public class TestPoisson { class TestPoisson {
private static final double DELTA = 1E-15; private static final double DELTA = 1E-15;

View File

@ -26,7 +26,7 @@ import org.junit.jupiter.api.Test;
import static org.junit.jupiter.api.Assertions.assertEquals; import static org.junit.jupiter.api.Assertions.assertEquals;
import static org.junit.jupiter.api.Assertions.assertTrue; import static org.junit.jupiter.api.Assertions.assertTrue;
public class TestProduct { class TestProduct {
@Test @Test
void missingArgsAreIgnored() { void missingArgsAreIgnored() {
ValueEval result = getInstance().evaluate(new ValueEval[]{new NumberEval(2.0), MissingArgEval.instance}, 0, 0); ValueEval result = getInstance().evaluate(new ValueEval[]{new NumberEval(2.0), MissingArgEval.instance}, 0, 0);

View File

@ -29,7 +29,7 @@ import org.junit.jupiter.api.Test;
* *
* @author cedric dot walter @ gmail dot com * @author cedric dot walter @ gmail dot com
*/ */
public class TestQuotient { class TestQuotient {
private static ValueEval invokeValue(String numerator, String denominator) { private static ValueEval invokeValue(String numerator, String denominator) {
ValueEval[] args = new ValueEval[]{new StringEval(numerator), new StringEval(denominator)}; ValueEval[] args = new ValueEval[]{new StringEval(numerator), new StringEval(denominator)};
return new Quotient().evaluate(args, -1, -1); return new Quotient().evaluate(args, -1, -1);

View File

@ -24,7 +24,7 @@ import org.junit.jupiter.params.provider.Arguments;
/** /**
* Tests QUOTIENT() as loaded from a test data spreadsheet.<p> * Tests QUOTIENT() as loaded from a test data spreadsheet.<p>
*/ */
public class TestQuotientFunctionsFromSpreadsheet extends BaseTestFunctionsFromSpreadsheet { class TestQuotientFunctionsFromSpreadsheet extends BaseTestFunctionsFromSpreadsheet {
public static Stream<Arguments> data() throws Exception { public static Stream<Arguments> data() throws Exception {
return data(TestQuotientFunctionsFromSpreadsheet.class, "QuotientFunctionTestCaseData.xls"); return data(TestQuotientFunctionsFromSpreadsheet.class, "QuotientFunctionTestCaseData.xls");
} }

View File

@ -27,7 +27,7 @@ import org.apache.poi.ss.formula.eval.StringEval;
import org.apache.poi.ss.formula.eval.ValueEval; import org.apache.poi.ss.formula.eval.ValueEval;
import org.junit.jupiter.api.Test; import org.junit.jupiter.api.Test;
public class TestRelationalOperations { class TestRelationalOperations {
/** /**
* (1, 1)(1, 1) = 1 * (1, 1)(1, 1) = 1

View File

@ -24,7 +24,7 @@ import org.junit.jupiter.params.provider.Arguments;
/** /**
* Tests REPT() as loaded from a test data spreadsheet.<p> * Tests REPT() as loaded from a test data spreadsheet.<p>
*/ */
public class TestReptFunctionsFromSpreadsheet extends BaseTestFunctionsFromSpreadsheet { class TestReptFunctionsFromSpreadsheet extends BaseTestFunctionsFromSpreadsheet {
public static Stream<Arguments> data() throws Exception { public static Stream<Arguments> data() throws Exception {
return data(TestReptFunctionsFromSpreadsheet.class, "ReptFunctionTestCaseData.xls"); return data(TestReptFunctionsFromSpreadsheet.class, "ReptFunctionTestCaseData.xls");
} }

View File

@ -24,7 +24,7 @@ import org.junit.jupiter.params.provider.Arguments;
/** /**
* Tests Roman() as loaded from a test data spreadsheet.<p> * Tests Roman() as loaded from a test data spreadsheet.<p>
*/ */
public class TestRomanFunctionsFromSpreadsheet extends BaseTestFunctionsFromSpreadsheet { class TestRomanFunctionsFromSpreadsheet extends BaseTestFunctionsFromSpreadsheet {
public static Stream<Arguments> data() throws Exception { public static Stream<Arguments> data() throws Exception {
return data(TestRomanFunctionsFromSpreadsheet.class, "RomanFunctionTestCaseData.xls"); return data(TestRomanFunctionsFromSpreadsheet.class, "RomanFunctionTestCaseData.xls");
} }

View File

@ -30,7 +30,7 @@ import org.junit.jupiter.api.Disabled;
import org.junit.jupiter.api.Test; import org.junit.jupiter.api.Test;
public class TestStatsLib extends BaseTestNumeric { class TestStatsLib extends BaseTestNumeric {
@Test @Test
void testDevsq() { void testDevsq() {

View File

@ -26,7 +26,7 @@ import org.junit.jupiter.api.Test;
import static org.junit.jupiter.api.Assertions.assertEquals; import static org.junit.jupiter.api.Assertions.assertEquals;
public class TestSubstitute { class TestSubstitute {
@Test @Test
void testSubstitute() { void testSubstitute() {
Substitute fun = new Substitute(); Substitute fun = new Substitute();

View File

@ -23,7 +23,7 @@ import org.junit.jupiter.params.provider.Arguments;
/** /**
* Tests TREND() as loaded from a test data spreadsheet. * Tests TREND() as loaded from a test data spreadsheet.
*/ */
public class TestTrendFunctionsFromSpreadsheet extends BaseTestFunctionsFromSpreadsheet { class TestTrendFunctionsFromSpreadsheet extends BaseTestFunctionsFromSpreadsheet {
public static Stream<Arguments> data() throws Exception { public static Stream<Arguments> data() throws Exception {
return data(TestTrendFunctionsFromSpreadsheet.class, "Trend.xls"); return data(TestTrendFunctionsFromSpreadsheet.class, "Trend.xls");
} }

View File

@ -25,7 +25,7 @@ import org.junit.jupiter.params.provider.Arguments;
* Tests for numeric functions with two arguments such aqs +, -, *, POWER * Tests for numeric functions with two arguments such aqs +, -, *, POWER
* as loaded from a test data spreadsheet. * as loaded from a test data spreadsheet.
*/ */
public class TestTwoOperandNumericFunctionsFromSpreadsheet extends BaseTestFunctionsFromSpreadsheet { class TestTwoOperandNumericFunctionsFromSpreadsheet extends BaseTestFunctionsFromSpreadsheet {
public static Stream<Arguments> data() throws Exception { public static Stream<Arguments> data() throws Exception {
return data(TestTwoOperandNumericFunctionsFromSpreadsheet.class, "TwoOperandNumericFunctionTestCaseData.xls"); return data(TestTwoOperandNumericFunctionsFromSpreadsheet.class, "TwoOperandNumericFunctionTestCaseData.xls");
} }

View File

@ -24,7 +24,7 @@ import org.junit.jupiter.params.provider.Arguments;
/** /**
* Tests WeekNum() as loaded from a test data spreadsheet.<p> * Tests WeekNum() as loaded from a test data spreadsheet.<p>
*/ */
public class TestWeekNumFunctionsFromSpreadsheet extends BaseTestFunctionsFromSpreadsheet { class TestWeekNumFunctionsFromSpreadsheet extends BaseTestFunctionsFromSpreadsheet {
public static Stream<Arguments> data() throws Exception { public static Stream<Arguments> data() throws Exception {
return data(TestWeekNumFunctionsFromSpreadsheet.class, "WeekNumFunctionTestCaseData.xls"); return data(TestWeekNumFunctionsFromSpreadsheet.class, "WeekNumFunctionTestCaseData.xls");
} }

View File

@ -24,7 +24,7 @@ import org.junit.jupiter.params.provider.Arguments;
/** /**
* Tests WeekNum() as loaded from a test data 2013 excel spreadsheet.<p> * Tests WeekNum() as loaded from a test data 2013 excel spreadsheet.<p>
*/ */
public class TestWeekNumFunctionsFromSpreadsheet2013 extends BaseTestFunctionsFromSpreadsheet { class TestWeekNumFunctionsFromSpreadsheet2013 extends BaseTestFunctionsFromSpreadsheet {
public static Stream<Arguments> data() throws Exception { public static Stream<Arguments> data() throws Exception {
//Only open this file with Excel 2013 to keep binary specific to that version //Only open this file with Excel 2013 to keep binary specific to that version
return data(TestWeekNumFunctionsFromSpreadsheet2013.class, "WeekNumFunctionTestCaseData2013.xls"); return data(TestWeekNumFunctionsFromSpreadsheet2013.class, "WeekNumFunctionTestCaseData2013.xls");

Some files were not shown because too many files have changed in this diff Show More