Package gov.nih.mipav.model.file
Class MetadataExtractorTest.RandomAccessTestBase
- java.lang.Object
-
- gov.nih.mipav.model.file.MetadataExtractorTest.RandomAccessTestBase
-
- Direct Known Subclasses:
MetadataExtractorTest.ByteArrayReaderTest,MetadataExtractorTest.RandomAccessFileReaderTest,MetadataExtractorTest.RandomAccessStreamReaderTest
- Enclosing class:
- MetadataExtractorTest
public abstract class MetadataExtractorTest.RandomAccessTestBase extends java.lang.ObjectBase class for testing implementations ofMetadataExtractor.RandomAccessReader.- Author:
- Drew Noakes https://drewnoakes.com
-
-
Constructor Summary
Constructors Constructor Description RandomAccessTestBase()
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description protected abstract MetadataExtractor.RandomAccessReadercreateReader(byte[] bytes)voidtestDefaultEndianness()voidtestGetBytesEOF()voidtestGetFloat32()voidtestGetFloat64()voidtestGetInt16()voidtestGetInt32()voidtestGetInt32_OutOfBounds()voidtestGetInt64()voidtestGetInt64_OutOfBounds()voidtestGetInt8()voidtestGetInt8EOF()voidtestGetNullTerminatedString()voidtestGetString()voidtestGetUInt16()voidtestGetUInt16_OutOfBounds()voidtestGetUInt32()voidtestGetUInt8()voidtestGetUInt8_OutOfBounds()voidtestIndexPlusCountExceedsIntMaxValue()voidtestOverflowBoundsCalculation()
-
-
-
Method Detail
-
createReader
protected abstract MetadataExtractor.RandomAccessReader createReader(byte[] bytes)
-
testDefaultEndianness
public void testDefaultEndianness()
-
testGetInt8
public void testGetInt8() throws java.lang.Exception- Throws:
java.lang.Exception
-
testGetUInt8
public void testGetUInt8() throws java.lang.Exception- Throws:
java.lang.Exception
-
testGetUInt8_OutOfBounds
public void testGetUInt8_OutOfBounds()
-
testGetInt16
public void testGetInt16() throws java.lang.Exception- Throws:
java.lang.Exception
-
testGetUInt16
public void testGetUInt16() throws java.lang.Exception- Throws:
java.lang.Exception
-
testGetUInt16_OutOfBounds
public void testGetUInt16_OutOfBounds()
-
testGetInt32
public void testGetInt32() throws java.lang.Exception- Throws:
java.lang.Exception
-
testGetUInt32
public void testGetUInt32() throws java.lang.Exception- Throws:
java.lang.Exception
-
testGetInt32_OutOfBounds
public void testGetInt32_OutOfBounds()
-
testGetInt64
public void testGetInt64() throws java.io.IOException- Throws:
java.io.IOException
-
testGetInt64_OutOfBounds
public void testGetInt64_OutOfBounds() throws java.lang.Exception- Throws:
java.lang.Exception
-
testGetFloat32
public void testGetFloat32() throws java.lang.Exception- Throws:
java.lang.Exception
-
testGetFloat64
public void testGetFloat64() throws java.lang.Exception- Throws:
java.lang.Exception
-
testGetNullTerminatedString
public void testGetNullTerminatedString() throws java.lang.Exception- Throws:
java.lang.Exception
-
testGetString
public void testGetString() throws java.lang.Exception- Throws:
java.lang.Exception
-
testIndexPlusCountExceedsIntMaxValue
public void testIndexPlusCountExceedsIntMaxValue()
-
testOverflowBoundsCalculation
public void testOverflowBoundsCalculation()
-
testGetBytesEOF
public void testGetBytesEOF() throws java.lang.Exception- Throws:
java.lang.Exception
-
testGetInt8EOF
public void testGetInt8EOF() throws java.lang.Exception- Throws:
java.lang.Exception
-
-