2014-11-20 13:30:47 +08:00
|
|
|
from __future__ import print_function
|
2007-06-15 05:01:26 +08:00
|
|
|
import glob
|
|
|
|
import os.path
|
|
|
|
for path in glob.glob( '*.json' ):
|
|
|
|
text = file(path,'rt').read()
|
|
|
|
target = os.path.splitext(path)[0] + '.expected'
|
|
|
|
if os.path.exists( target ):
|
2014-11-20 13:30:47 +08:00
|
|
|
print('skipping:', target)
|
2007-06-15 05:01:26 +08:00
|
|
|
else:
|
2014-11-20 13:30:47 +08:00
|
|
|
print('creating:', target)
|
2007-06-15 05:01:26 +08:00
|
|
|
file(target,'wt').write(text)
|
|
|
|
|