Updated tests

This commit is contained in:
Vitaly Puzrin 2014-03-19 21:07:30 +04:00
parent b525b6dca4
commit f47bb620ad
3 changed files with 24 additions and 0 deletions

BIN
test/fixtures/blank.gif vendored Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 49 B

View file

@ -137,6 +137,9 @@ function testInflate(samples, inflateOptions, deflateOptions, callback) {
//
for (name in samples) {
data = samples[name];
// always use the same data type to generate sample
pako_utils.setTyped(true);
deflated = pako.deflate(data, deflateOptions);
// with untyped arrays

View file

@ -123,9 +123,30 @@ describe('Inflate strategy', function () {
describe('Inflate RAW', function () {
// Since difference is only in rwapper, test for store/fast/slow methods are enougth
it('level 9', function(done) {
testInflate(samples, { raw: true }, { level: 9, raw: true }, done);
});
it('level 8', function(done) {
testInflate(samples, { raw: true }, { level: 8, raw: true }, done);
});
it('level 7', function(done) {
testInflate(samples, { raw: true }, { level: 7, raw: true }, done);
});
it('level 6', function(done) {
testInflate(samples, { raw: true }, { level: 6, raw: true }, done);
});
it('level 5', function(done) {
testInflate(samples, { raw: true }, { level: 5, raw: true }, done);
});
it('level 4', function(done) {
testInflate(samples, { raw: true }, { level: 4, raw: true }, done);
});
it('level 3', function(done) {
testInflate(samples, { raw: true }, { level: 3, raw: true }, done);
});
it('level 2', function(done) {
testInflate(samples, { raw: true }, { level: 2, raw: true }, done);
});
it('level 1', function(done) {
testInflate(samples, { raw: true }, { level: 1, raw: true }, done);
});