57
57
DeprecationWarning)
58
58
macostools.touched(test_support.TESTFN)
65
macostools.copy(test_support.TESTFN, TESTFN2)
66
self.assertEqual(self.compareData(), '')
68
def test_mkalias(self):
73
macostools.mkalias(test_support.TESTFN, TESTFN2)
74
fss, _, _ = Carbon.File.ResolveAliasFile(TESTFN2, 0)
75
self.assertEqual(fss.as_pathname(), os.path.realpath(test_support.TESTFN))
77
def test_mkalias_relative(self):
82
# If the directory doesn't exist, then chances are this is a new
83
# install of Python so don't create it since the user might end up
84
# running ``sudo make install`` and creating the directory here won't
85
# leave it with the proper permissions.
86
if not os.path.exists(sys.prefix):
88
macostools.mkalias(test_support.TESTFN, TESTFN2, sys.prefix)
89
fss, _, _ = Carbon.File.ResolveAliasFile(TESTFN2, 0)
90
self.assertEqual(fss.as_pathname(), os.path.realpath(test_support.TESTFN))
60
if sys.maxint < 2**32:
66
macostools.copy(test_support.TESTFN, TESTFN2)
67
self.assertEqual(self.compareData(), '')
69
if sys.maxint < 2**32:
70
def test_mkalias(self):
75
macostools.mkalias(test_support.TESTFN, TESTFN2)
76
fss, _, _ = Carbon.File.ResolveAliasFile(TESTFN2, 0)
77
self.assertEqual(fss.as_pathname(), os.path.realpath(test_support.TESTFN))
79
def test_mkalias_relative(self):
84
# If the directory doesn't exist, then chances are this is a new
85
# install of Python so don't create it since the user might end up
86
# running ``sudo make install`` and creating the directory here won't
87
# leave it with the proper permissions.
88
if not os.path.exists(sys.prefix):
90
macostools.mkalias(test_support.TESTFN, TESTFN2, sys.prefix)
91
fss, _, _ = Carbon.File.ResolveAliasFile(TESTFN2, 0)
92
self.assertEqual(fss.as_pathname(), os.path.realpath(test_support.TESTFN))