/*
- * Copyright 2013 Facebook, Inc.
+ * Copyright 2014 Facebook, Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* limitations under the License.
*/
-#include "folly/io/Compression.h"
+#include <folly/io/Compression.h>
// Yes, tr1, as that's what gtest requires
#include <random>
#include <glog/logging.h>
#include <gtest/gtest.h>
-#include "folly/Benchmark.h"
-#include "folly/Hash.h"
-#include "folly/Random.h"
-#include "folly/io/IOBufQueue.h"
+#include <folly/Benchmark.h>
+#include <folly/Hash.h>
+#include <folly/Random.h>
+#include <folly/io/IOBufQueue.h>
namespace folly { namespace io { namespace test {
EXPECT_FALSE(getCodec(CodecType::SNAPPY)->needsUncompressedLength());
EXPECT_FALSE(getCodec(CodecType::ZLIB)->needsUncompressedLength());
EXPECT_FALSE(getCodec(CodecType::LZ4_VARINT_SIZE)->needsUncompressedLength());
+ EXPECT_TRUE(getCodec(CodecType::LZMA2)->needsUncompressedLength());
+ EXPECT_FALSE(getCodec(CodecType::LZMA2_VARINT_SIZE)
+ ->needsUncompressedLength());
}
class CompressionTest : public testing::TestWithParam<
CodecType::LZ4,
CodecType::SNAPPY,
CodecType::ZLIB,
- CodecType::LZ4_VARINT_SIZE)));
+ CodecType::LZ4_VARINT_SIZE,
+ CodecType::LZMA2,
+ CodecType::LZMA2_VARINT_SIZE)));
class CompressionCorruptionTest : public testing::TestWithParam<CodecType> {
protected: