MDFactoryMDFactory

conftest

funcmake_test_record(hash_value, status='build', **overrides)dict[str, str]

Create a test database record for RUN_DATABASE.

paramhash_valuestr

Simulation hash

paramstatusstr
= 'build'

Simulation status (default: "build")

paramoverridesAny
= {}

Returns

dict

Record dict suitable for DataManager.save_data()

func_sample_rows()list[dict[str, object]]

Sample CSV rows for creating test BuildInput models.

Uses simple 3-character residue names and simple SMILES to avoid validation issues in tests. Returns 2 rows with different total_count to generate unique hashes.

Returns

list[dict[str, object]]
func_write_csv_with_models(tmp_path)tuple[Path, list]

Create a CSV file and return path and BuildInput models.

paramtmp_pathPath

Returns

tuple[pathlib.Path, list]
func_create_simulation_folder(tmp_path, hash_value, status, build_input)Path

Create a complete simulation folder with appropriate status files.

Status files created based on status parameter:

  • "completed": prod.gro
  • "production": prod.xtc (but NOT prod.gro)
  • "equilibrated": min.gro, nvt.gro, npt.gro (but NOT prod.xtc or prod.gro)
  • "build": no simulation output files

Also creates system.pdb structure file for Simulation class compatibility.

paramtmp_pathPath
paramhash_valuestr
paramstatusstr
parambuild_input

Returns

pathlib.Path
functemp_run_db(tmp_path, monkeypatch)

Force RUN_DATABASE to use a temporary sqlite file.

paramtmp_path
parammonkeypatch

Returns

None
functemp_analysis_db(tmp_path, monkeypatch)

Force analysis database to use a temporary sqlite file.

paramtmp_path
parammonkeypatch

Returns

None