mirror of
https://github.com/GNS3/gns3-server.git
synced 2026-11-03 22:11:14 +02:00
"Local" command line parameter is only for stopping
a server that has been started by the desktop GUI
This commit is contained in:
1 parent
8975f63e2f
commit
900d4f79ee
18 files changed
+138
-186
No files matched your search
@@ -23,17 +23,11 @@ from fastapi import HTTPException
|
||||
from gns3server.utils.path import check_path_allowed, get_default_project_directory
|
||||
|
||||
|
||||
def test_check_path_allowed(config, tmpdir):
|
||||
def test_check_path_allowed():
|
||||
|
||||
config.settings.Server.local = False
|
||||
config.settings.Server.projects_path = str(tmpdir)
|
||||
with pytest.raises(HTTPException):
|
||||
check_path_allowed("/private")
|
||||
|
||||
config.settings.Server.local = True
|
||||
check_path_allowed(str(tmpdir / "hello" / "world"))
|
||||
check_path_allowed("/private")
|
||||
|
||||
|
||||
def test_get_default_project_directory(config):
|
||||
|
||||
|
||||
Reference in new issue
Block a user