Skip to content

Commit 5530183

Browse files
committed
Add unittest to account for new workspace functionality
Signed-off-by: lelia <lelia@socket.dev>
1 parent a7c1b9c commit 5530183

File tree

1 file changed

+18
-0
lines changed

1 file changed

+18
-0
lines changed
Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
from socketsecurity.socketcli import _normalize_workspace
2+
3+
4+
def test_normalize_workspace_none():
5+
assert _normalize_workspace(None) is None
6+
7+
8+
def test_normalize_workspace_empty_string():
9+
assert _normalize_workspace("") is None
10+
11+
12+
def test_normalize_workspace_whitespace_string():
13+
assert _normalize_workspace(" ") is None
14+
15+
16+
def test_normalize_workspace_valid_string():
17+
assert _normalize_workspace("my-workspace") == "my-workspace"
18+

0 commit comments

Comments
 (0)