diff --git a/.github/workflows/github-actions.yml b/.github/workflows/github-actions.yml index 3338ec25..37cb52f6 100644 --- a/.github/workflows/github-actions.yml +++ b/.github/workflows/github-actions.yml @@ -74,6 +74,12 @@ jobs: python_arch: 'x64' tox_env: 'py311' os: 'macos-latest' + - name: 'py311 (windows)' + python: '3.11' + toxpython: 'python3.11' + python_arch: 'x64' + tox_env: 'py311' + os: 'windows-latest' # - name: 'pypy38 (ubuntu)' # python: 'pypy-3.8' diff --git a/src/hip_ra/HIP_RA.py b/src/hip_ra/HIP_RA.py index b751cadb..b835771e 100755 --- a/src/hip_ra/HIP_RA.py +++ b/src/hip_ra/HIP_RA.py @@ -767,7 +767,7 @@ def render_scientific(p: floatParameter | OutputParameter) -> str: case_data = {'SUMMARY OF RESULTS': summary_of_results} with open(outputfile, 'w', encoding='UTF-8') as f: - nl = os.linesep + nl = '\n' f.write(f' *********************{nl}') f.write(f' ***HIP CASE REPORT***{nl}') diff --git a/tests/base_test_case.py b/tests/base_test_case.py index 5b652259..6776466e 100644 --- a/tests/base_test_case.py +++ b/tests/base_test_case.py @@ -56,8 +56,8 @@ def assertListAlmostEqual(self, l1, l2, msg=None, places=7): self.assertAlmostEqual(v1, v2, places=places, msg=msg) def assertFileContentsEqual(self, f1, f2): - with open(f1) as f1_o: - with open(f2) as f2_o: + with open(f1, newline=None) as f1_o: # newline=None enables universal line endings which is required by Windows + with open(f2, newline=None) as f2_o: f1_lines = f1_o.readlines() f2_lines = f2_o.readlines() self.assertListEqual(f1_lines, f2_lines)