Skip to content

Commit

Permalink
update mode:cloud-only (#15)
Browse files Browse the repository at this point in the history
  • Loading branch information
SAKURA-CAT authored Jul 17, 2024
1 parent 11a6867 commit 8540d8f
Show file tree
Hide file tree
Showing 3 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 @@ -9,7 +9,7 @@ build-backend = "hatchling.build"

[project]
name = "swankit"
version = "0.1.1b1"
version = "0.1.1b2"
dynamic = ["readme"]
description = "Base toolkit for SwanLab"
license = "Apache-2.0"
Expand Down
2 changes: 1 addition & 1 deletion swankit/env.py
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ class SwanLabMode(Enum):

DISABLED = "disabled"
CLOUD = "cloud"
# CLOUD_ONLY = "cloud-only"
CLOUD_ONLY = "cloud-only"
LOCAL = "local"

@classmethod
Expand Down
9 changes: 9 additions & 0 deletions test/unit/test_env.py
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,15 @@ def test_create_time():
assert d.tzinfo == datetime.timezone.utc


def test_list_mode():
ms = E.SwanLabMode.list()
assert len(ms) == 4
assert "disabled" in ms
assert "cloud" in ms
assert "cloud-only" in ms
assert "local" in ms


class TestGetFolder:
"""
测试获取全局保存文件夹
Expand Down

0 comments on commit 8540d8f

Please sign in to comment.