|
29 | 29 | import java.nio.file.Files;
|
30 | 30 | import java.nio.file.Path;
|
31 | 31 | import java.nio.file.Paths;
|
32 |
| -import java.util.Arrays; |
33 | 32 | import java.util.zip.GZIPInputStream;
|
34 | 33 | import java.util.zip.GZIPOutputStream;
|
35 | 34 | import org.apache.commons.compress.archivers.tar.TarArchiveEntry;
|
@@ -132,26 +131,6 @@ public void testToBlob_multiByte() throws IOException {
|
132 | 131 | Assert.assertNull(tarArchiveInputStream.getNextTarEntry());
|
133 | 132 | }
|
134 | 133 |
|
135 |
| - @Test |
136 |
| - public void testTarStreamAreReproducible() throws IOException, InterruptedException { |
137 |
| - testTarStreamBuilder.addBlobEntry( |
138 |
| - Blobs.from("jib"), "jib".getBytes(StandardCharsets.UTF_8).length, "jib"); |
139 |
| - ByteArrayOutputStream firstTarByteOutputStream = new ByteArrayOutputStream(); |
140 |
| - testTarStreamBuilder.writeAsTarArchiveTo(firstTarByteOutputStream); |
141 |
| - |
142 |
| - Thread.sleep(2000); |
143 |
| - |
144 |
| - TarStreamBuilder anotherTestTarStreamBuilder = new TarStreamBuilder(); |
145 |
| - anotherTestTarStreamBuilder.addBlobEntry( |
146 |
| - Blobs.from("jib"), "jib".getBytes(StandardCharsets.UTF_8).length, "jib"); |
147 |
| - ByteArrayOutputStream secondTarByteOutputStream = new ByteArrayOutputStream(); |
148 |
| - anotherTestTarStreamBuilder.writeAsTarArchiveTo(secondTarByteOutputStream); |
149 |
| - |
150 |
| - Assert.assertTrue( |
151 |
| - Arrays.equals( |
152 |
| - firstTarByteOutputStream.toByteArray(), secondTarByteOutputStream.toByteArray())); |
153 |
| - } |
154 |
| - |
155 | 134 | /** Creates a TarStreamBuilder using TarArchiveEntries. */
|
156 | 135 | private void setUpWithTarEntries() {
|
157 | 136 | // Prepares a test TarStreamBuilder.
|
|
0 commit comments