aiida.backends.tests.tools.importexport.orm package¶
Submodules¶
Extras tests for the export and import routines
-
class
aiida.backends.tests.tools.importexport.orm.test_attributes.
TestAttributes
(methodName='runTest')[source]¶ Bases:
aiida.backends.testbase.AiidaTestCase
Test ex-/import cases related to Attributes
-
__module__
= 'aiida.backends.tests.tools.importexport.orm.test_attributes'¶
-
test_import_of_attributes
(**kwargs)¶
-
orm.CalcNode tests for the export and import routines
-
class
aiida.backends.tests.tools.importexport.orm.test_calculations.
TestCalculations
(methodName='runTest')[source]¶ Bases:
aiida.backends.testbase.AiidaTestCase
Test ex-/import cases related to Calculations
-
__module__
= 'aiida.backends.tests.tools.importexport.orm.test_calculations'¶
-
test_calcfunction
(**kwargs)¶
-
test_workcalculation
(**kwargs)¶
-
orm.Code tests for the export and import routines
-
class
aiida.backends.tests.tools.importexport.orm.test_codes.
TestCode
(methodName='runTest')[source]¶ Bases:
aiida.backends.testbase.AiidaTestCase
Test ex-/import cases related to Codes
-
__module__
= 'aiida.backends.tests.tools.importexport.orm.test_codes'¶
-
test_input_code
(**kwargs)¶
-
test_solo_code
(**kwargs)¶
-
test_that_solo_code_is_exported_correctly
(**kwargs)¶
-
orm.Comment tests for the export and import routines
-
class
aiida.backends.tests.tools.importexport.orm.test_comments.
TestComments
(methodName='runTest')[source]¶ Bases:
aiida.backends.testbase.AiidaTestCase
Test ex-/import cases related to Comments
-
__module__
= 'aiida.backends.tests.tools.importexport.orm.test_comments'¶
-
test_calc_and_data_nodes_with_comments
(**kwargs)¶
-
test_exclude_comments_flag
(**kwargs)¶
-
test_import_arg_comment_mode
(**kwargs)¶
-
test_mtime_of_imported_comments
(**kwargs)¶
-
test_multiple_imports_for_single_node
(**kwargs)¶
-
test_multiple_user_comments_single_node
(**kwargs)¶
-
test_reimport_of_comments_for_single_node
(**kwargs)¶
-
orm.Computer tests for the export and import routines
-
class
aiida.backends.tests.tools.importexport.orm.test_computers.
TestComputer
(methodName='runTest')[source]¶ Bases:
aiida.backends.testbase.AiidaTestCase
Test ex-/import cases related to Computers
-
__module__
= 'aiida.backends.tests.tools.importexport.orm.test_computers'¶
-
test_different_computer_same_name_import
(**kwargs)¶
-
test_import_of_computer_json_params
(**kwargs)¶
-
test_import_of_django_sqla_export_file
()[source]¶ Check that sqla import manages to import the django export file correctly
-
test_same_computer_different_name_import
(**kwargs)¶
-
test_same_computer_import
(**kwargs)¶
-
Extras tests for the export and import routines
-
class
aiida.backends.tests.tools.importexport.orm.test_extras.
TestExtras
(methodName='runTest')[source]¶ Bases:
aiida.backends.testbase.AiidaTestCase
Test ex-/import cases related to Extras
-
__module__
= 'aiida.backends.tests.tools.importexport.orm.test_extras'¶
-
test_absence_of_extras
()[source]¶ Check whether extras are not imported if the mode is set to ‘none’
-
test_extras_import_mode_keep_existing
()[source]¶ Check if old extras are not modified in case of name collision
-
test_extras_import_mode_mirror
()[source]¶ Check if old extras are fully overwritten by the imported ones
-
test_extras_import_mode_none
()[source]¶ Check if old extras are fully overwritten by the imported ones
-
test_extras_import_mode_strange
()[source]¶ Check a mode that is probably does not make much sense but is still available
-
orm.Group tests for the export and import routines
-
class
aiida.backends.tests.tools.importexport.orm.test_groups.
TestGroups
(methodName='runTest')[source]¶ Bases:
aiida.backends.testbase.AiidaTestCase
Test ex-/import cases related to Groups
-
__module__
= 'aiida.backends.tests.tools.importexport.orm.test_groups'¶
-
test_group_export
(**kwargs)¶
-
test_group_import_existing
(**kwargs)¶
-
test_import_to_group
(**kwargs)¶
-
test_nodes_in_group
(**kwargs)¶
-
orm links tests for the export and import routines
-
class
aiida.backends.tests.tools.importexport.orm.test_links.
TestLinks
(methodName='runTest')[source]¶ Bases:
aiida.backends.testbase.AiidaTestCase
Test ex-/import cases related to Links
-
__module__
= 'aiida.backends.tests.tools.importexport.orm.test_links'¶
-
construct_complex_graph
(export_combination=0, work_nodes=None, calc_nodes=None)[source]¶ This method creates a “complex” graph with all available link types: INPUT_WORK, INPUT_CALC, CALL_WORK, CALL_CALC, CREATE, and RETURN and returns the nodes of the graph. It also returns various combinations of nodes that need to be extracted but also the final expected set of nodes (after adding the expected predecessors, desuccessors).
Graph:
data1 ---------------INPUT_WORK----------------+ | | | data2 -INPUT_WORK-+ | | V V +-------INPUT_WORK--> work1 --CALL_WORK--> work2 ----+ | | | | CALL_CALC---------------------+ | | | +-> data3 <-+ | | V | | | +--INPUT_CALC--> calc1 --CREATE-+-> data4 <-+-----RETURN +-> data5 | | INPUT_CALC--> calc2 --CREATE-+-> data6
-
link_flags_export_helper
(name, all_nodes, temp_dir, nodes_to_export, flags, expected_nodes)[source]¶ Helper function
-
test_complex_workflow_graph_export_sets
(**kwargs)¶
-
test_complex_workflow_graph_links
(**kwargs)¶
-
test_dangling_link_to_existing_db_node
(**kwargs)¶
-
test_double_return_links_for_workflows
(**kwargs)¶
-
test_high_level_workflow_links
(**kwargs)¶
-
test_input_and_create_links
(**kwargs)¶
-
test_link_flags
(**kwargs)¶
-
test_links_to_unknown_nodes
(**kwargs)¶
-
test_multiple_post_return_links
(**kwargs)¶
-
orm.Log tests for the export and import routines
-
class
aiida.backends.tests.tools.importexport.orm.test_logs.
TestLogs
(methodName='runTest')[source]¶ Bases:
aiida.backends.testbase.AiidaTestCase
Test ex-/import cases related to Logs
-
__module__
= 'aiida.backends.tests.tools.importexport.orm.test_logs'¶
-
test_critical_log_msg_and_metadata
(**kwargs)¶
-
test_exclude_logs_flag
(**kwargs)¶
-
test_export_of_imported_logs
(**kwargs)¶
-
test_multiple_imports_for_single_node
(**kwargs)¶
-
test_reimport_of_logs_for_single_node
(**kwargs)¶
-
orm.User tests for the export and import routines
-
class
aiida.backends.tests.tools.importexport.orm.test_users.
TestUsers
(methodName='runTest')[source]¶ Bases:
aiida.backends.testbase.AiidaTestCase
Test ex-/import cases related to Users
-
__module__
= 'aiida.backends.tests.tools.importexport.orm.test_users'¶
-
test_nodes_belonging_to_different_users
(**kwargs)¶
-
test_non_default_user_nodes
(**kwargs)¶
-