Skip to content

Commit 00a1141

Browse files
author
NITHIVARSHA T P
committed
fix: add type annotations and apply formatting to version tests
1 parent 9837010 commit 00a1141

File tree

1 file changed

+7
-8
lines changed

1 file changed

+7
-8
lines changed

tests/test_version.py

Lines changed: 7 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,26 +1,25 @@
11
"""Tests for zarr._version module"""
2-
import pytest
3-
import importlib
4-
import sys
52

63

7-
def test_version_is_available():
4+
def test_version_is_available() -> None:
85
"""Test that __version__ is available and is a string."""
96
from zarr import __version__
7+
108
assert __version__ is not None
119
assert isinstance(__version__, str)
1210
assert len(__version__) > 0
1311

1412

15-
def test_version_format():
13+
def test_version_format() -> None:
1614
"""Test that version follows basic format."""
1715
from zarr import __version__
16+
1817
assert isinstance(__version__, str)
1918
# Basic check: should contain a dot or dash
20-
assert '.' in __version__ or '-' in __version__
19+
assert "." in __version__ or "-" in __version__
2120

2221

23-
def test_version_is_not_unknown_in_normal_case():
22+
def test_version_is_not_unknown_in_normal_case() -> None:
2423
from zarr import __version__
25-
assert __version__ != "unknown"
2624

25+
assert __version__ != "unknown"

0 commit comments

Comments
 (0)