fix r/o mapped memory on temp for ci
This commit is contained in:
parent
eef285ae1f
commit
3a6dedfd46
1 changed files with 3 additions and 5 deletions
|
@ -5,8 +5,8 @@ import net.openhft.chronicle.core.OS;
|
||||||
import net.openhft.chronicle.core.io.IOTools;
|
import net.openhft.chronicle.core.io.IOTools;
|
||||||
import org.junit.After;
|
import org.junit.After;
|
||||||
import org.junit.Assert;
|
import org.junit.Assert;
|
||||||
|
import org.junit.Ignore;
|
||||||
import org.junit.Test;
|
import org.junit.Test;
|
||||||
import org.junit.jupiter.api.Disabled;
|
|
||||||
|
|
||||||
import java.io.File;
|
import java.io.File;
|
||||||
import java.io.FileNotFoundException;
|
import java.io.FileNotFoundException;
|
||||||
|
@ -344,7 +344,7 @@ public class MappedBytesTest extends BytesTestCommon {
|
||||||
bytes.releaseLast();
|
bytes.releaseLast();
|
||||||
}
|
}
|
||||||
|
|
||||||
@Disabled("concourse ci")
|
@Ignore("concourse ci")
|
||||||
@Test
|
@Test
|
||||||
public void shouldBeReadOnly() throws Exception {
|
public void shouldBeReadOnly() throws Exception {
|
||||||
final File tempFile = File.createTempFile("mapped", "bytes");
|
final File tempFile = File.createTempFile("mapped", "bytes");
|
||||||
|
@ -352,9 +352,7 @@ public class MappedBytesTest extends BytesTestCommon {
|
||||||
raf.setLength(4096);
|
raf.setLength(4096);
|
||||||
assertTrue(tempFile.setWritable(false));
|
assertTrue(tempFile.setWritable(false));
|
||||||
final MappedBytes mappedBytes = MappedBytes.readOnly(tempFile);
|
final MappedBytes mappedBytes = MappedBytes.readOnly(tempFile);
|
||||||
|
assertTrue(mappedBytes.isBackingFileReadOnly());
|
||||||
assertTrue(mappedBytes.
|
|
||||||
isBackingFileReadOnly());
|
|
||||||
mappedBytes.releaseLast();
|
mappedBytes.releaseLast();
|
||||||
assertEquals(0, mappedBytes.refCount());
|
assertEquals(0, mappedBytes.refCount());
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue