Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 349b04e

Browse files
committed
Issue 19384: Fix test_py_compile for root user, patch by Claudiu Popa.
1 parent c4a4b34 commit 349b04e

2 files changed

Lines changed: 8 additions & 0 deletions

File tree

Lib/test/test_py_compile.py

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@
33
import py_compile
44
import shutil
55
import stat
6+
import sys
67
import tempfile
78
import unittest
89

@@ -75,6 +76,8 @@ def test_relative_path(self):
7576
self.assertTrue(os.path.exists(self.pyc_path))
7677
self.assertFalse(os.path.exists(self.cache_path))
7778

79+
@unittest.skipIf(hasattr(os, 'geteuid') and os.geteuid() == 0,
80+
'non-root user required')
7881
@unittest.skipIf(os.name == 'nt',
7982
'cannot control directory permissions on Windows')
8083
def test_exceptions_propagate(self):

Misc/NEWS

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -74,6 +74,11 @@ Library
7474

7575
- Issue #17087: Improved the repr for regular expression match objects.
7676

77+
Tests
78+
-----
79+
80+
- Issue 19384: Fix test_py_compile for root user, patch by Claudiu Popa.
81+
7782
Build
7883
-----
7984

0 commit comments

Comments
 (0)