blob: 6a935faa8524c177d3cc884f0d4523546e979a9e [file] [log] [blame]
iarkh16c110b2021-05-10 21:43:47 +07001// Copyright (c) 2017, the Dart project authors. Please see the AUTHORS file
2// for details. All rights reserved. Use of this source code is governed by a
3// BSD-style license that can be found in the LICENSE file.
4
sgrekhovbd1a4232021-05-11 12:08:20 +07005/// @assertion
6/// ZLibCodec({
7/// int level: ZLibOption.DEFAULT_LEVEL,
8/// int windowBits: ZLibOption.DEFAULT_WINDOW_BITS,
9/// int memLevel: ZLibOption.DEFAULT_MEM_LEVEL,
10/// int strategy: ZLibOption.strategyDefault,
11/// List<int> dictionary: null,
12/// bool raw: false,
13/// bool gzip: false
14/// })
15/// @description Checks that this constructor creates a new ZLibCodec object
16/// with specified [gzip] parameters.
17/// @author ngl@unipro.ru
18
Sergey G. Grekhov45dcc9d2018-10-08 16:17:23 +070019import "dart:io";
20import "../../../Utils/expect.dart";
21
22main() {
23 ZLibCodec v = new ZLibCodec(gzip: true);
sgrekhovea2d0722020-08-13 12:32:02 +070024 Expect.equals(ZLibOption.defaultLevel, v.level);
25 Expect.equals(ZLibOption.defaultWindowBits, v.windowBits);
26 Expect.equals(ZLibOption.defaultMemLevel, v.memLevel);
27 Expect.equals(ZLibOption.strategyDefault, v.strategy);
Sergey G. Grekhov45dcc9d2018-10-08 16:17:23 +070028 Expect.equals(null, v.dictionary);
29 Expect.equals(false, v.raw);
30 Expect.equals(true, v.gzip);
31}