Skip to content

Commit

Permalink
update tests
Browse files Browse the repository at this point in the history
  • Loading branch information
CuriousDolphin committed Feb 3, 2025
1 parent 9f49a73 commit dcce6f4
Showing 1 changed file with 0 additions and 15 deletions.
15 changes: 0 additions & 15 deletions tests/test_ports.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,6 @@
from pytest_mock import MockerFixture

from focoos.ports import (
DatasetLayout,
DatasetPreview,
GPUInfo,
Hyperparameters,
SystemInfo,
Expand All @@ -30,19 +28,6 @@ def test_validate_wandb_project_invalid():
assert "Wandb project name must only contain characters, dashes, underscores, and dots." in str(exc_info.value)


def test_validate_s3_url_valid():
url = "s3://bucketname/path"
dataset = DatasetPreview(url=url, name="test", layout=DatasetLayout.CATALOG)
assert dataset.url == url


def test_validate_s3_url_invalid():
url = "invalid_url"
with pytest.raises(ValidationError) as exc_info:
DatasetPreview(url=url, name="test", layout=DatasetLayout.CATALOG)
assert "Invalid S3 URL format, must be s3://BUCKET_NAME/path" in str(exc_info.value)


def test_pretty_print_with_gpus_info(mocker: MockerFixture):
gpu_info = GPUInfo(
gpu_id=0,
Expand Down

0 comments on commit dcce6f4

Please sign in to comment.