aboutsummaryrefslogtreecommitdiff
path: root/src/test/test_buffers.c
diff options
context:
space:
mode:
authorNick Mathewson <nickm@torproject.org>2017-05-02 08:33:35 -0400
committerNick Mathewson <nickm@torproject.org>2017-05-02 08:33:35 -0400
commit584ab1f29b05b6cd0c63c16668b1c260a957656b (patch)
treee25d2ada2d3e714808440284346403ad635ae32c /src/test/test_buffers.c
parent465448e659e6cbaecc1494b5cf270f556e104bd4 (diff)
parent3836d9481f81cc1617a9a48de2c2ca178f4804c8 (diff)
downloadtor-584ab1f29b05b6cd0c63c16668b1c260a957656b.tar.gz
tor-584ab1f29b05b6cd0c63c16668b1c260a957656b.zip
Merge branch 'compress_none_v2_squashed'
Diffstat (limited to 'src/test/test_buffers.c')
-rw-r--r--src/test/test_buffers.c8
1 files changed, 7 insertions, 1 deletions
diff --git a/src/test/test_buffers.c b/src/test/test_buffers.c
index c0e222bbb1..07114a8571 100644
--- a/src/test/test_buffers.c
+++ b/src/test/test_buffers.c
@@ -611,7 +611,11 @@ test_buffers_compress_fin_at_chunk_end_impl(compress_method_t method,
tt_int_op(fetch_from_buf(contents, in_len, buf), OP_EQ, 0);
- tt_uint_op(in_len, OP_GT, headerjunk);
+ if (method == NO_METHOD) {
+ tt_uint_op(in_len, OP_EQ, headerjunk);
+ } else {
+ tt_uint_op(in_len, OP_GT, headerjunk);
+ }
tt_int_op(0, OP_EQ, tor_uncompress(&expanded, &out_len,
contents + headerjunk,
@@ -855,6 +859,8 @@ struct testcase_t buffer_tests[] = {
&passthrough_setup, (char*)"x-zstd" },
{ "compress/lzma", test_buffers_compress, TT_FORK,
&passthrough_setup, (char*)"x-tor-lzma" },
+ { "compress/none", test_buffers_compress, TT_FORK,
+ &passthrough_setup, (char*)"identity" },
END_OF_TESTCASES
};