Skip to content

Commit

Permalink
FIX: update test package version to be dynamic (#352)
Browse files Browse the repository at this point in the history
  • Loading branch information
SMoraisAnsys authored Jan 18, 2024
1 parent 87825f9 commit bd568a5
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 2 deletions.
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ build-backend = "flit_core.buildapi"
[project]
# Check https://flit.readthedocs.io/en/latest/pyproject_toml.html for all available sections
name = "ansys-edb-core"
version = "0.1"
version = "0.1.0"
description = "A python wrapper for Ansys Edb service"
readme = "README.rst"
requires-python = ">=3.8"
Expand Down
11 changes: 10 additions & 1 deletion tests/mock/test_metadata.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,13 @@


def test_pkg_version():
assert __version__ == "0.1"
try:
import importlib.metadata as importlib_metadata
except ModuleNotFoundError: # pragma: no cover
import importlib_metadata

# Read from the pyproject.toml
# major, minor, patch
read_version = importlib_metadata.version("ansys-edb-core")

assert __version__ == read_version

0 comments on commit bd568a5

Please sign in to comment.