4
%% Copyright Ericsson AB 2005-2009. All Rights Reserved.
4
%% Copyright Ericsson AB 2005-2011. All Rights Reserved.
6
6
%% The contents of this file are subject to the Erlang Public License,
7
7
%% Version 1.1, (the "License"); you may not use this file except in
48
48
init_per_testcase(_Func, Config) ->
49
49
Dog = test_server:timetrap(test_server:seconds(60)),
50
50
[{watchdog, Dog}|Config].
51
fin_per_testcase(_Func, Config) ->
51
end_per_testcase(_Func, Config) ->
52
52
Dog = ?config(watchdog, Config),
53
53
test_server:timetrap_cancel(Dog).
70
70
%% log("<>ERROR<>~n" ++ Format, Args, File, Line).
73
[api, examples, func, smp, otp_7359].
75
api(doc) -> "Basic the api tests";
79
api_deflateSetDictionary,
85
api_inflateSetDictionary,
72
suite() -> [{ct_hooks,[ts_install_cth]}].
75
[{group, api}, {group, examples}, {group, func}, smp,
80
[api_open_close, api_deflateInit,
81
api_deflateSetDictionary, api_deflateReset,
82
api_deflateParams, api_deflate, api_deflateEnd,
83
api_inflateInit, api_inflateSetDictionary,
84
api_inflateSync, api_inflateReset, api_inflate,
85
api_inflateEnd, api_setBufsz, api_getBufsz, api_crc32,
86
api_adler32, api_getQSize, api_un_compress, api_un_zip,
88
{examples, [], [intro]},
90
[zip_usage, gz_usage, gz_usage2, compress_usage,
91
dictionary_usage, large_deflate, crc, adler]}].
93
init_per_suite(Config) ->
96
end_per_suite(_Config) ->
99
init_per_group(_GroupName, Config) ->
102
end_per_group(_GroupName, Config) ->
100
107
api_open_close(doc) -> "Test open/0 and close/1";
101
108
api_open_close(suite) -> [];
517
524
%% zlib:zip(<<42>>), one byte changed.
518
525
<<31,139,8,0,0,0,0,0,0,3,211,2,0,91,38,185,9,2,0,0,0>>.
520
examples(doc) -> "Test the doc examples";
526
528
intro(suite) -> [];
527
529
intro(doc) -> "";
551
553
Orig = list_to_binary(lists:duplicate(5, D)),
552
554
?m(Orig, zlib:uncompress(Res)).
554
func(doc) -> "Test the functionality";
556
[zip_usage, gz_usage, gz_usage2, compress_usage,
564
557
large_deflate(doc) -> "Test deflate large file, which had a bug reported on erlang-bugs";
565
558
large_deflate(suite) -> [];