Skip to content

Commit

Permalink
Update
Browse files Browse the repository at this point in the history
  • Loading branch information
Xiang Song committed Sep 26, 2024
1 parent c8167b3 commit 39a65cc
Showing 1 changed file with 4 additions and 15 deletions.
19 changes: 4 additions & 15 deletions tests/unit-tests/test_gsf.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@
Unit tests for gsf.py
"""
import pytest

from graphstorm.gsf import (create_builtin_node_decoder,
create_builtin_edge_decoder,
Expand Down Expand Up @@ -464,28 +465,16 @@ def test_check_graph_name():

# test with invalid graph name
graph_name = "/graph_name"
invalid_name = False
try:
with pytest.raises(AssertionError):
check_graph_name(graph_name)
except:
invalid_name = True
assert invalid_name

graph_name = "|graph_name"
invalid_name = False
try:
with pytest.raises(AssertionError):
check_graph_name(graph_name)
except:
invalid_name = True
assert invalid_name

graph_name = "\graph_name"
invalid_name = False
try:
with pytest.raises(AssertionError):
check_graph_name(graph_name)
except:
invalid_name = True
assert invalid_name

if __name__ == '__main__':
test_check_graph_name()
Expand Down

0 comments on commit 39a65cc

Please sign in to comment.