Skip to content

Commit

Permalink
dueling formatters
Browse files Browse the repository at this point in the history
  • Loading branch information
hausman-gdit committed Feb 5, 2024
1 parent e52c262 commit fcb7d56
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 12 deletions.
12 changes: 3 additions & 9 deletions bmds_server/analysis/reporting/docx.py
Original file line number Diff line number Diff line change
Expand Up @@ -57,20 +57,14 @@ def build_docx(

bmds_version = analysis.get_bmds_version()
if bmds_version:
write_setting_p(
report, "BMDS version: ", f"{bmds_version.pretty} ({bmds_version.dll})"
)
write_setting_p(report, "BMDS version: ", f"{bmds_version.pretty} ({bmds_version.dll})")

write_setting_p(report, "BMDS Online version: ", str(settings.COMMIT))

if not analysis.is_finished:
report.document.add_paragraph(
"Execution is incomplete; no report could be generated"
)
report.document.add_paragraph("Execution is incomplete; no report could be generated")
elif analysis.has_errors:
report.document.add_paragraph(
"Execution generated errors; no report can be generated"
)
report.document.add_paragraph("Execution generated errors; no report can be generated")
else:
batch = analysis.to_batch()
batch.to_docx(
Expand Down
4 changes: 1 addition & 3 deletions tests/conftest.py
Original file line number Diff line number Diff line change
Expand Up @@ -38,9 +38,7 @@ def vcr_config():

@pytest.fixture(scope="module")
def vcr_cassette_dir(request):
cassette_dir = (
Path(__file__).parent.absolute() / "cassettes" / request.module.__name__
)
cassette_dir = Path(__file__).parent.absolute() / "cassettes" / request.module.__name__
return str(cassette_dir)


Expand Down

0 comments on commit fcb7d56

Please sign in to comment.