Skip to content

Commit

Permalink
fix test_data - added downloading
Browse files Browse the repository at this point in the history
  • Loading branch information
robin-janssen committed Sep 24, 2024
1 parent a0eec38 commit d45820e
Show file tree
Hide file tree
Showing 4 changed files with 3 additions and 21 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -23,3 +23,4 @@ scripts
build/
dist/
*.egg-info/
data.hdf5
3 changes: 0 additions & 3 deletions data/osu2008/data.hdf5

This file was deleted.

18 changes: 1 addition & 17 deletions pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,16 +1,11 @@
# This section describes the requirements of the build/installation
# process itself. Being able to do this was the original reason to
# introduce pyproject.toml
[build-system]
requires = [
"setuptools >=61",
"setuptools_scm >=7",
]
build-backend = "setuptools.build_meta"

# This section provides general project metadata that is used across
# a variety of build tools. Notably, the version specified here is the
# single source of truth for CODES's version

[project]
name = "CODES"
description = "Benchmarking tool for neural (chemical) ODE surrogate models"
Expand Down Expand Up @@ -55,23 +50,12 @@ dev = [
# ]


# The following section contains setuptools-specific configuration
# options. For a full reference of available options, check the overview
# at https://setuptools.pypa.io/en/latest/userguide/pyproject_config.html
[tool.setuptools]
packages = [
"codes",
]

# Configure setuptools_scm, which extracts the version number from
# the version control system. For more information see its documentation:
# https://github.com/pypa/setuptools_scm
# [tool.setuptools_scm]
# version_scheme = "post-release"
# local_scheme = "node-and-date"
# write_to = "CODES/_version.py"

# The following is the configuration for the pytest test suite
[tool.pytest.ini_options]
testpaths = [
"test",
Expand Down
2 changes: 1 addition & 1 deletion test/test_data.py
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ def dataset(request: pytest.FixtureRequest):

def test_check_and_load_data(dataset):
try:
download_data(dataset)
_ = check_and_load_data(dataset)
except Exception as e:
pytest.fail(f"Failed to load data for {dataset}: {e}")
Expand All @@ -32,4 +33,3 @@ def test_download_data(dataset, tmp_path: Path):
def test_download_data_invalid_dataset():
with pytest.raises(ValueError):
download_data("invalid_dataset")

0 comments on commit d45820e

Please sign in to comment.