Skip to content

Commit 0123e24

Browse files
authored
Enable Brotli tests on m1 (#12705)
Motivation: a06f851 updated brotli4j version to one that supports m1. Let's enable tests. Modifications: Enable brotli4j tests on m1 as well Result: More testing
1 parent 8dd357c commit 0123e24

2 files changed

Lines changed: 0 additions & 15 deletions

File tree

codec/src/test/java/io/netty/handler/codec/compression/BrotliDecoderTest.java

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -21,11 +21,9 @@
2121
import io.netty.buffer.CompositeByteBuf;
2222
import io.netty.buffer.Unpooled;
2323
import io.netty.channel.embedded.EmbeddedChannel;
24-
import io.netty.util.internal.PlatformDependent;
2524
import org.junit.jupiter.api.AfterEach;
2625
import org.junit.jupiter.api.BeforeAll;
2726
import org.junit.jupiter.api.BeforeEach;
28-
import org.junit.jupiter.api.condition.DisabledIf;
2927
import org.junit.jupiter.params.ParameterizedTest;
3028
import org.junit.jupiter.params.provider.MethodSource;
3129

@@ -35,9 +33,7 @@
3533

3634
import static org.junit.jupiter.api.Assertions.assertEquals;
3735
import static org.junit.jupiter.api.Assertions.assertTrue;
38-
import static org.junit.jupiter.api.Assumptions.assumeTrue;
3936

40-
@DisabledIf(value = "isNotSupported", disabledReason = "Brotli is not supported on this platform")
4137
public class BrotliDecoderTest {
4238

4339
private static Random RANDOM;
@@ -66,10 +62,6 @@ static void setUp() {
6662
private static final ByteBuf WRAPPED_BYTES_LARGE = Unpooled.unreleasableBuffer(
6763
Unpooled.wrappedBuffer(BYTES_LARGE)).asReadOnly();
6864

69-
static boolean isNotSupported() {
70-
return PlatformDependent.isOsx() && "aarch_64".equals(PlatformDependent.normalizedArch());
71-
}
72-
7365
private static void fillArrayWithCompressibleData(byte[] array) {
7466
for (int i = 0; i < array.length; i++) {
7567
array[i] = i % 4 != 0 ? 0 : (byte) RANDOM.nextInt();

codec/src/test/java/io/netty/handler/codec/compression/BrotliEncoderTest.java

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -22,11 +22,8 @@
2222
import io.netty.buffer.CompositeByteBuf;
2323
import io.netty.buffer.Unpooled;
2424
import io.netty.channel.embedded.EmbeddedChannel;
25-
import io.netty.util.internal.PlatformDependent;
2625
import org.junit.jupiter.api.BeforeAll;
27-
import org.junit.jupiter.api.condition.DisabledIf;
2826

29-
@DisabledIf(value = "isNotSupported", disabledReason = "Brotli is not supported on this platform")
3027
public class BrotliEncoderTest extends AbstractEncoderTest {
3128

3229
@BeforeAll
@@ -71,8 +68,4 @@ protected ByteBuf readDecompressed(final int dataLength) throws Exception {
7168
}
7269
return decompressed;
7370
}
74-
75-
static boolean isNotSupported() {
76-
return PlatformDependent.isOsx() && "aarch_64".equals(PlatformDependent.normalizedArch());
77-
}
7871
}

0 commit comments

Comments
 (0)