aiida.backends.tests.orm.node package¶
Submodules¶
Tests for the Node ORM class.
-
class
aiida.backends.tests.orm.node.test_node.
TestNodeLinks
(methodName='runTest')[source]¶ Bases:
aiida.backends.testbase.AiidaTestCase
Test for linking from and to Node.
-
__module__
= 'aiida.backends.tests.orm.node.test_node'¶
-
test_add_incoming_call_calc
()[source]¶ Nodes can only have a single incoming CALL_CALC link, independent of the source node.
-
test_add_incoming_call_work
()[source]¶ Nodes can only have a single incoming CALL_WORK link, independent of the source node.
-
test_add_incoming_create
()[source]¶ Nodes can only have a single incoming CREATE link, independent of the source node.
-
test_add_incoming_input_calc
()[source]¶ Nodes can have an infinite amount of incoming INPUT_CALC links, as long as the link pair is unique.
-
test_add_incoming_input_work
()[source]¶ Nodes can have an infinite amount of incoming INPUT_WORK links, as long as the link pair is unique.
-
test_add_incoming_return
()[source]¶ Nodes can have an infinite amount of incoming RETURN links, as long as the link triple is unique.
-
test_computer_user_immutability
()[source]¶ Test that computer and user of a node are immutable after storing.
-
test_get_node_by_label
()[source]¶ Test the get_node_by_label() method of the LinkManager
In particular, check both the it returns the correct values, but also that it raises the expected exceptions where appropriate (missing link with a given label, or more than one link)
-
test_node_indegree_unique_pair
()[source]¶ Test that the validation of links with indegree unique_pair works correctly
The example here is a DataNode that has two incoming links with the same label, but with different types. This is legal and should pass validation.
-
test_node_indegree_unique_triple
()[source]¶ Test that the validation of links with indegree unique_triple works correctly
The example here is a DataNode that has two incoming RETURN links with the same label, but from different source nodes. This is legal and should pass validation.
-
test_node_outdegree_unique_triple
()[source]¶ Test that the validation of links with outdegree unique_triple works correctly
The example here is a CalculationNode that has two outgoing CREATE links with the same label, but to different target nodes. This is legal and should pass validation.
-
test_repository_garbage_collection
()[source]¶ Verify that the repository sandbox folder is cleaned after the node instance is garbage collected.
-