text files on Unix should end with a new line character
This commit is contained in:
parent
84353ae545
commit
3a51e1119b
|
@ -303,7 +303,9 @@ class Colormap(mpl.colors.ListedColormap):
|
|||
'RGBPoints':colors
|
||||
}]
|
||||
|
||||
json.dump(out,self._get_file_handle(fname,'json'),indent=4)
|
||||
fhandle = self._get_file_handle(fname,'json')
|
||||
json.dump(out,fhandle,indent=4)
|
||||
fhandle.write('\n')
|
||||
|
||||
|
||||
def save_ASCII(self,fname=None):
|
||||
|
|
|
@ -388,9 +388,9 @@ class TestResult:
|
|||
cur = hashlib.md5(f.read().encode()).hexdigest()
|
||||
if update:
|
||||
with open((ref_path/'export_VTK'/request.node.name).with_suffix('.md5'),'w') as f:
|
||||
f.write(cur)
|
||||
f.write(cur+'\n')
|
||||
with open((ref_path/'export_VTK'/request.node.name).with_suffix('.md5')) as f:
|
||||
assert cur == f.read()
|
||||
assert cur == f.read()[:-1]
|
||||
|
||||
@pytest.mark.parametrize('mode',['point','cell'])
|
||||
@pytest.mark.parametrize('output',[False,True])
|
||||
|
|
Loading…
Reference in New Issue