1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17 package org.apache.commons.imaging.formats.png.scanlinefilters;
18
19 import static org.junit.jupiter.api.Assertions.assertArrayEquals;
20
21 import java.io.IOException;
22
23 import org.apache.commons.imaging.ImagingException;
24 import org.junit.jupiter.api.Test;
25
26 public class ScanlineFilterAverageTest {
27
28 @Test
29 public void testUnfilterWithNull() throws IOException, ImagingException {
30 final ScanlineFilterAverage scanlineFilterAverage = new ScanlineFilterAverage(2);
31 final byte[] byteArray = new byte[9];
32 scanlineFilterAverage.unfilter(byteArray, byteArray, null);
33
34 assertArrayEquals(new byte[] { (byte) 0, (byte) 0, (byte) 0, (byte) 0, (byte) 0, (byte) 0, (byte) 0, (byte) 0, (byte) 0 }, byteArray);
35 }
36
37 }