public class CompressionTestBase extends Object
Modifier and Type | Field and Description |
---|---|
protected static int |
BLOCK_SIZE |
protected static int |
LARGE_SIZE |
protected static org.slf4j.Logger |
LOG |
protected static byte[] |
SMALL_INPUT |
protected static int |
VERY_LARGE_SIZE |
Constructor and Description |
---|
CompressionTestBase() |
Modifier and Type | Method and Description |
---|---|
protected void |
codecLargeTest(org.apache.hadoop.io.compress.CompressionCodec codec,
double sigma)
Test with a large input (1MB) divided into blocks of 4KB.
|
protected void |
codecSmallTest(org.apache.hadoop.io.compress.CompressionCodec codec)
Test with one smallish input buffer
|
protected void |
codecTest(org.apache.hadoop.io.compress.CompressionCodec codec,
byte[][] input) |
protected void |
codecTest(org.apache.hadoop.io.compress.CompressionCodec codec,
byte[][] input,
Integer expectedCompressedSize) |
protected void |
codecVeryLargeTest(org.apache.hadoop.io.compress.CompressionCodec codec,
double sigma)
Test with a very large input (100MB) as a single input buffer.
|
protected static void |
fill(RandomDistribution.DiscreteRNG rng,
byte[] input) |
protected static void |
fill(RandomDistribution.DiscreteRNG rng,
byte[][] input) |
protected static final org.slf4j.Logger LOG
protected static final int LARGE_SIZE
protected static final int VERY_LARGE_SIZE
protected static final int BLOCK_SIZE
protected static final byte[] SMALL_INPUT
public CompressionTestBase()
protected void codecTest(org.apache.hadoop.io.compress.CompressionCodec codec, byte[][] input) throws Exception
Exception
protected void codecTest(org.apache.hadoop.io.compress.CompressionCodec codec, byte[][] input, Integer expectedCompressedSize) throws Exception
Exception
protected void codecSmallTest(org.apache.hadoop.io.compress.CompressionCodec codec) throws Exception
Exception
protected void codecLargeTest(org.apache.hadoop.io.compress.CompressionCodec codec, double sigma) throws Exception
Exception
protected void codecVeryLargeTest(org.apache.hadoop.io.compress.CompressionCodec codec, double sigma) throws Exception
Exception
protected static void fill(RandomDistribution.DiscreteRNG rng, byte[][] input)
protected static void fill(RandomDistribution.DiscreteRNG rng, byte[] input)
Copyright © 2007–2020 The Apache Software Foundation. All rights reserved.