Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix test warnings #543

Merged
merged 7 commits into from
Nov 8, 2024
Merged

fix test warnings #543

merged 7 commits into from
Nov 8, 2024

Conversation

jgrewe
Copy link
Member

@jgrewe jgrewe commented Jul 26, 2024

This PR fixes

  • warnings during tests that are related to the datetime deprecation warnings.
  • We should further be able to work with numpy versions > 2.0
  • disables the documentation script tests as they led to a lot of CI failures

# Render matplotlib plots non-blocking
plt.ion()

def tearDown(self):
plt.close("all")
plt.ioff()
if Path.exists(Path("TEST_IMAGE")):
Path.unlink(Path(TEST_IMAGE))
Path.unlink(Path(TEST_IMAGE), True)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Unrelated to this PR but should the line above be Path.exists(Path(TEST_IMAGE)) (instead of the string "TEST_IMAGE")?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

good catch!

@@ -97,7 +97,8 @@ def time_to_str(time):
:return: string in the form "YYYYMMDDTHHMMSS", where T is the date-time separator
:rtype: str
"""
dt = datetime.utcfromtimestamp(time)
# dt = datetime.utcfromtimestamp(time)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Any reason to keep the old line around as a comment? I think we can just delete it.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

a long time ago, it must have made sense ;) removed with the updated version

nixio/test/test_doc_examples.py Show resolved Hide resolved
@achilleas-k achilleas-k merged commit beec115 into G-Node:master Nov 8, 2024
21 checks passed
@jgrewe jgrewe deleted the warnings branch November 8, 2024 11:42
@jgrewe
Copy link
Member Author

jgrewe commented Nov 8, 2024

Thanks, @achilleas-k !

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants