We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 41e437f commit 1d9516cCopy full SHA for 1d9516c
packages/vite/src/node/__tests__/utils.spec.ts
@@ -296,11 +296,14 @@ describe('isFileReadable', () => {
296
fs.chmodSync(testFile, '400')
297
expect(isFileReadable(testFile)).toBe(true)
298
})
299
- test('file without read permission', async () => {
300
- fs.chmodSync(testFile, '044')
301
- expect(isFileReadable(testFile)).toBe(false)
302
- fs.chmodSync(testFile, '644')
303
- })
+ test.runIf(process.getuid && process.getuid() !== 0)(
+ 'file without read permission',
+ async () => {
+ fs.chmodSync(testFile, '044')
+ expect(isFileReadable(testFile)).toBe(false)
304
+ fs.chmodSync(testFile, '644')
305
+ },
306
+ )
307
}
308
309
0 commit comments