1
0
mirror of https://github.com/GNS3/gns3-server synced 2024-12-23 23:38:21 +00:00

Fix create a node from a template test.

This commit is contained in:
grossmj 2019-02-22 18:44:12 +07:00
parent 5754747a90
commit 4487e578bc

View File

@ -961,7 +961,7 @@ def test_create_node_from_template(http_controller, controller, project, compute
"default_name_format": "{name}-{0}",
"compute_id": "example.com"
})}
with asyncio_patch("gns3server.controller.project.Project.add_node_from_template") as mock:
with asyncio_patch("gns3server.controller.project.Project.add_node_from_template", return_value={"name": "test", "node_type": "qemu", "compute_id": "example.com"}) as mock:
response = http_controller.post("/projects/{}/templates/{}".format(project.id, id), {
"x": 42,
"y": 12