Skip to content

Commit 0e1c8b2

Browse files
committed
Fix bugs
1 parent 5d6f46e commit 0e1c8b2

File tree

2 files changed

+6
-3
lines changed

2 files changed

+6
-3
lines changed

tests/test-pyarmor.py

+3-1
Original file line numberDiff line numberDiff line change
@@ -193,7 +193,9 @@ def test_parse_manifest_file(self):
193193
f.write('include foo.py main.py')
194194

195195
filelist = fm(args, srcpath=workpath)
196-
self.assertEquals(filelist, [('foo.py', 'foo'), ('main.py', 'main')])
196+
self.assertEquals(filelist, [
197+
(os.path.join(workpath, 'foo.py'), 'foo'),
198+
(os.path.join(workpath, 'main.py'), 'main')])
197199

198200
def test_do_encrypt_empty_file(self):
199201
ft = self.pyarmor.do_encrypt

tests/test-trial-pyarmor.py

+3-2
Original file line numberDiff line numberDiff line change
@@ -104,10 +104,11 @@ def test_encrypt_files(self):
104104
ft = self.pyarmor.encrypt_files
105105
names = 'main.py', 'foo.py'
106106
files = [os.path.join(workpath, x) for x in names]
107+
files = [(x, os.path.splitext(x)[0]) for x in files]
107108
prokey = os.path.join(workpath, 'project', 'product.key')
108109
ft(files, prokey)
109-
self.assertTrue(os.path.exists(files[0] + ext_char))
110-
self.assertTrue(os.path.exists(files[1] + ext_char))
110+
self.assertTrue(os.path.exists(files[0][0] + ext_char))
111+
self.assertTrue(os.path.exists(files[1][0] + ext_char))
111112

112113
def test_make_license(self):
113114
ft = self.pyarmor.make_license

0 commit comments

Comments
 (0)