Skip to content

Commit

Permalink
POSIX permissions won't work on Windows
Browse files Browse the repository at this point in the history
  • Loading branch information
botic committed Aug 8, 2018
1 parent 18f955b commit 93f235e
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions test/ringo/utils/files_test.js
Original file line number Diff line number Diff line change
Expand Up @@ -105,6 +105,10 @@ exports.testPosixPermissions = function() {
};

exports.testCreateTempFileWithPermissions = function () {
if (!java.nio.file.FileSystems.getDefault().supportedFileAttributeViews().contains("posix")) {
return;
}

let tempFile = files.createTempFile("ringo", null, null, 0000);
assert.isNotNull(tempFile); // Creation w/ prefix only.
assert.isTrue(/[\/\\]ringo\w*\.tmp$/.test(tempFile));
Expand Down

0 comments on commit 93f235e

Please sign in to comment.