Skip to content

Commit

Permalink
Lower precision in strings of basis export
Browse files Browse the repository at this point in the history
  • Loading branch information
marvinfriede committed Jun 28, 2024
1 parent 83082d0 commit 0a869f5
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 1 deletion.
2 changes: 1 addition & 1 deletion src/dxtb/__version__.py
Original file line number Diff line number Diff line change
Expand Up @@ -22,5 +22,5 @@

__all__ = ["__version__", "__tversion__"]

__version__ = "0.0.1"
__version__ = "0.0.0"
"""Version of ``dxtb`` in semantic versioning."""
13 changes: 13 additions & 0 deletions test/test_basis/test_export.py
Original file line number Diff line number Diff line change
Expand Up @@ -63,4 +63,17 @@ def test_export(
with open(p, encoding="utf-8") as f:
content = f.read()

def round_numbers(data):
rounded_data = []
for item in data:
try:
rounded_item = round(float(item), 10)
rounded_data.append(rounded_item)
except ValueError:
rounded_data.append(item)
return rounded_data

content = round_numbers(content.split())
txt = round_numbers(txt.split())

assert content == txt

0 comments on commit 0a869f5

Please sign in to comment.