schrodinger.application.models.test.test_objects module¶
- schrodinger.application.models.test.test_objects.make_definition(definition_id='def123')¶
- schrodinger.application.models.test.test_objects.make_def_and_config(config_id='config123', definition_id='def123')¶
- schrodinger.application.models.test.test_objects.make_def_and_config_with_file(file_path, config_id='config123', definition_id='def123')¶
Create a definition/config pair that includes a FILE input.
- Parameters:
file_path – The file path to set as the FILE input value.
config_id – The configuration ID.
definition_id – The definition ID.
- Returns:
A (ModelDefinition, ModelConfiguration) tuple.
- schrodinger.application.models.test.test_objects.make_configuration(config_id='config123', definition_id='def123')¶
Create a test ModelConfiguration with the given IDs.
- schrodinger.application.models.test.test_objects.make_model()¶
- schrodinger.application.models.test.test_objects.add_child_config(composite)¶
Create a new config as a child of the composite’s bottom config and add it.
Helper for tests that need to add configs without using the factory directly.
- schrodinger.application.models.test.test_objects.add_child_input_config(composite_input)¶
Create a new input config and add it to the composite input.
Helper for tests that need to add input configs without using the factory directly.
- schrodinger.application.models.test.test_objects.make_linear_config_tree(levels)¶
Create a tree of model.configs with the given number of levels. Each config has a parent config, except for the root config.
- schrodinger.application.models.test.test_objects.make_start_end_times()¶
Create a pair of start and end times for testing.
- schrodinger.application.models.test.test_objects.write_csv_files()¶
- schrodinger.application.models.test.test_objects.write_col_csv_file(filename, row_dicts)¶
- schrodinger.application.models.test.test_objects.create_configs(configs, library)¶
- schrodinger.application.models.test.test_objects.get_example_library_source_path() Path¶
Return the path to the bundled example library source files.
- schrodinger.application.models.test.test_objects.get_builtin_library_source_path() Path¶
Return the path to the bundled builtin library source files.
- schrodinger.application.models.test.test_objects.get_example_library_path() Path¶
Copy the bundled example library to the current working directory. If it already exists, it will be overwritten.
- Returns:
Path to the copied library in CWD.
- schrodinger.application.models.test.test_objects.make_input_violation(input_config=None, parent_constraint: ChildConstraint | None = None) InputViolation¶
Create a mock InputViolation for testing.
- Parameters:
input_config – The input config with the violation. If provided, the violation will be associated with this input for lookup purposes.
parent_constraint – If provided, the parent_input mock will return this from getConstraint(). Only needed for tests that check messages.