mirror of
https://github.com/GNS3/gns3-server.git
synced 2026-11-03 05:51:15 +02:00
Remove --controller
This add too much complexity and it can work without it. Fix https://github.com/GNS3/gns3-vm/issues/80, #645
This commit is contained in:
7 files changed
+2
-33
No files matched your search
@@ -205,7 +205,6 @@ def run_around_tests(monkeypatch, port_manager, controller, config):
|
||||
config.set("Server", "images_path", os.path.join(tmppath, 'images'))
|
||||
config.set("Server", "ubridge_path", os.path.join(tmppath, 'bin', 'ubridge'))
|
||||
config.set("Server", "auth", False)
|
||||
config.set("Server", "controller", True)
|
||||
|
||||
# Prevent executions of the VM if we forgot to mock something
|
||||
config.set("VirtualBox", "vboxmanage_path", tmppath)
|
||||
|
||||
@@ -222,13 +222,6 @@ def test_load_projects(controller, projects_dir, async_run):
|
||||
mock_load_project.assert_called_with(os.path.join(projects_dir, "project1", "project1.gns3"), load=False)
|
||||
|
||||
|
||||
def test_isEnabled(controller):
|
||||
Config.instance().set("Server", "controller", False)
|
||||
assert not controller.is_enabled()
|
||||
Config.instance().set("Server", "controller", True)
|
||||
assert controller.is_enabled()
|
||||
|
||||
|
||||
def test_add_compute(controller, controller_config_path, async_run):
|
||||
controller._notification = MagicMock()
|
||||
c = async_run(controller.add_compute(compute_id="test1", connect=False))
|
||||
|
||||
@@ -49,12 +49,6 @@ def test_version_invalid_input(http_controller):
|
||||
'status': 409}
|
||||
|
||||
|
||||
def test_version_not_controller(http_controller, config):
|
||||
config.set("Server", "controller", False)
|
||||
response = http_controller.get('/version')
|
||||
assert response.status == 403
|
||||
|
||||
|
||||
def test_version_invalid_input_schema(http_controller):
|
||||
query = {'version': "0.4.2", "bla": "blu"}
|
||||
response = http_controller.post('/version', query)
|
||||
|
||||
Reference in new issue
Block a user