Make a test compatible across python versions.
This commit is contained in:
parent
ded5ee0013
commit
f37f423ac1
@ -1,2 +1,2 @@
|
||||
all:
|
||||
python2.7 test.py
|
||||
python test.py
|
||||
|
@ -33,7 +33,7 @@ def check_lib(lib):
|
||||
print('verifying if {} is an unstable crate'.format(lib['name']))
|
||||
stdout, stderr = exec_command([os.environ['RUSTC'], '-', '--crate-type', 'rlib',
|
||||
'--extern', '{}={}'.format(lib['name'], lib['path'])],
|
||||
to_input='extern crate {};'.format(lib['name']))
|
||||
to_input=('extern crate {};'.format(lib['name'])).encode('utf-8'))
|
||||
if not 'use of unstable library feature' in '{}{}'.format(stdout, stderr):
|
||||
print('crate {} "{}" is not unstable'.format(lib['name'], lib['path']))
|
||||
print('{}{}'.format(stdout, stderr))
|
||||
|
Loading…
Reference in New Issue
Block a user