hbat 2.2.11.dev29__tar.gz → 2.2.12__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {hbat-2.2.11.dev29 → hbat-2.2.12}/PKG-INFO +2 -2
- {hbat-2.2.11.dev29 → hbat-2.2.12}/README.md +1 -1
- {hbat-2.2.11.dev29 → hbat-2.2.12}/docs/source/index.rst +2 -2
- {hbat-2.2.11.dev29 → hbat-2.2.12}/hbat/_version.py +2 -2
- {hbat-2.2.11.dev29 → hbat-2.2.12}/tests/cli/test_cli_output_formats.py +181 -77
- {hbat-2.2.11.dev29 → hbat-2.2.12}/.github/workflows/cleanup-prereleases.yml +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/.github/workflows/release.yml +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/.github/workflows/test.yml +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/CITATION.cff +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/CODE_OF_CONDUCT.md +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/CONTRIBUTING.md +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/LICENSE +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/MANIFEST.in +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/Makefile +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/build_standalone.py +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/build_standalone_linux.py +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/build_standalone_windows.py +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/conda/meta.yaml +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/docs/Makefile +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/docs/requirements.txt +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/docs/source/_static/custom.css +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/docs/source/_static/light-theme.css +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/docs/source/api/ccd/ccd_analyzer.rst +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/docs/source/api/ccd/constants_generator.rst +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/docs/source/api/ccd/generate_ccd_constants.rst +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/docs/source/api/ccd/index.rst +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/docs/source/api/cli/index.rst +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/docs/source/api/constants/app.rst +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/docs/source/api/constants/atomic_data.rst +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/docs/source/api/constants/index.rst +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/docs/source/api/constants/misc.rst +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/docs/source/api/constants/parameters.rst +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/docs/source/api/constants/pdb_constants.rst +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/docs/source/api/core/index.rst +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/docs/source/api/core/interactions.rst +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/docs/source/api/core/np_analyzer.rst +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/docs/source/api/core/np_vector.rst +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/docs/source/api/core/pdb_fixer.rst +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/docs/source/api/core/pdb_parser.rst +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/docs/source/api/core/structure.rst +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/docs/source/api/examples/index.rst +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/docs/source/api/gui/index.rst +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/docs/source/api/index.rst +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/docs/source/api/utilities/atom_utils.rst +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/docs/source/api/utilities/graphviz_utils.rst +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/docs/source/api/utilities/index.rst +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/docs/source/cli.rst +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/docs/source/conf.py +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/docs/source/development.rst +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/docs/source/installation.rst +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/docs/source/license.rst +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/docs/source/logic.rst +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/docs/source/parameters.rst +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/docs/source/pdbfixing.rst +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/docs/source/quickstart.rst +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/example_pdb_files/1bhl.pdb +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/example_pdb_files/1gai.pdb +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/example_pdb_files/1ubi.pdb +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/example_pdb_files/2izf.pdb +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/example_pdb_files/4jsv.pdb +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/example_pdb_files/4laz.pdb +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/example_pdb_files/4ub7.pdb +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/example_pdb_files/4x21.pdb +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/example_pdb_files/6rsa.pdb +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/example_presets/drug_design_strict.hbat +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/example_presets/high_resolution.hbat +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/example_presets/low_resolution.hbat +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/example_presets/membrane_proteins.hbat +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/example_presets/nmr_structures.hbat +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/example_presets/standard_resolution.hbat +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/example_presets/strong_interactions_only.hbat +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/example_presets/weak_interactions_permissive.hbat +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/hbat/__init__.py +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/hbat/ccd/__init__.py +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/hbat/ccd/ccd_analyzer.py +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/hbat/ccd/constants_generator.py +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/hbat/ccd/generate_ccd_constants.py +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/hbat/cli/__init__.py +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/hbat/cli/main.py +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/hbat/constants/__init__.py +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/hbat/constants/app.py +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/hbat/constants/atomic_data.py +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/hbat/constants/misc.py +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/hbat/constants/parameters.py +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/hbat/constants/pdb_constants.py +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/hbat/constants/residue_bonds.py +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/hbat/core/__init__.py +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/hbat/core/analysis.py +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/hbat/core/analyzer.py +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/hbat/core/app_config.py +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/hbat/core/atom_classifier.py +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/hbat/core/interactions.py +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/hbat/core/np_analyzer.py +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/hbat/core/np_vector.py +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/hbat/core/pdb_fixer.py +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/hbat/core/pdb_parser.py +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/hbat/core/structure.py +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/hbat/gui/__init__.py +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/hbat/gui/chain_visualization.py +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/hbat/gui/export_manager.py +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/hbat/gui/graphviz_preferences_dialog.py +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/hbat/gui/graphviz_renderer.py +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/hbat/gui/main_window.py +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/hbat/gui/matplotlib_renderer.py +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/hbat/gui/parameter_panel.py +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/hbat/gui/results_panel.py +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/hbat/gui/visualization_renderer.py +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/hbat/utilities/__init__.py +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/hbat/utilities/atom_utils.py +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/hbat/utilities/graphviz_utils.py +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/hbat.egg-info/SOURCES.txt +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/hbat.icns +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/hbat.ico +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/hbat.png +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/hbat.svg +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/hbat_cli.py +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/hbat_gui.py +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/pyproject.toml +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/pytest.ini +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/requirements-dev.txt +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/requirements.txt +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/setup.cfg +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/tests/README.md +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/tests/__init__.py +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/tests/cli/__init__.py +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/tests/cli/test_cli_main.py +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/tests/conftest.py +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/tests/e2e/__init__.py +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/tests/e2e/test_cli_workflows.py +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/tests/e2e/test_complete_workflows.py +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/tests/e2e/test_graphviz_workflows.py +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/tests/e2e/test_gui_workflows.py +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/tests/gui/__init__.py +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/tests/gui/test_gui_components.py +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/tests/integration/__init__.py +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/tests/integration/test_analyzer_components.py +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/tests/integration/test_cli_integration.py +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/tests/integration/test_graphviz_renderer.py +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/tests/integration/test_molecular_validation.py +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/tests/integration/test_pdb_parsing.py +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/tests/performance/__init__.py +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/tests/performance/test_ccd_performance.py +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/tests/performance/test_performance_workflows.py +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/tests/run_tests.py +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/tests/unit/__init__.py +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/tests/unit/test_cli_parsing.py +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/tests/unit/test_graphviz_utils.py +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/tests/unit/test_gui_components.py +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/tests/unit/test_interactions.py +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/tests/unit/test_parameters.py +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/tests/unit/test_scrollable_canvas.py +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/tests/unit/test_structures.py +0 -0
- {hbat-2.2.11.dev29 → hbat-2.2.12}/tests/unit/test_vector_math.py +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: hbat
|
|
3
|
-
Version: 2.2.
|
|
3
|
+
Version: 2.2.12
|
|
4
4
|
Summary: Hydrogen Bond Analysis Tool for PDB structures
|
|
5
5
|
Author-email: Abhishek Tiwari <hbat@abhishek-tiwari.com>
|
|
6
6
|
License-Expression: MIT
|
|
@@ -86,7 +86,7 @@ A Python package to automate the analysis of potential hydrogen bonds and simila
|
|
|
86
86
|

|
|
87
87
|
[](https://codecov.io/gh/abhishektiwari/hbat)
|
|
88
88
|
[&replace=%241&style=plastic&logo=googlescholar&label=Cited%20By&cacheSeconds=86400)](https://scholar.google.com/citations?view_op=view_citation&hl=en&user=Mb7eYKYAAAAJ&citation_for_view=Mb7eYKYAAAAJ:u-x6o8ySG0sC)
|
|
89
|
-
[](https://socket.dev/pypi/package/hbat/overview/2.2.11/py3-none-any-whl)
|
|
90
90
|
[](https://www.codefactor.io/repository/github/abhishektiwari/hbat/overview/main)
|
|
91
91
|
|
|
92
92
|
## Background
|
|
@@ -18,7 +18,7 @@ A Python package to automate the analysis of potential hydrogen bonds and simila
|
|
|
18
18
|

|
|
19
19
|
[](https://codecov.io/gh/abhishektiwari/hbat)
|
|
20
20
|
[&replace=%241&style=plastic&logo=googlescholar&label=Cited%20By&cacheSeconds=86400)](https://scholar.google.com/citations?view_op=view_citation&hl=en&user=Mb7eYKYAAAAJ&citation_for_view=Mb7eYKYAAAAJ:u-x6o8ySG0sC)
|
|
21
|
-
[](https://socket.dev/pypi/package/hbat/overview/2.2.11/py3-none-any-whl)
|
|
22
22
|
[](https://www.codefactor.io/repository/github/abhishektiwari/hbat/overview/main)
|
|
23
23
|
|
|
24
24
|
## Background
|
|
@@ -56,9 +56,9 @@ HBAT Documentation
|
|
|
56
56
|
:alt: Cited by Google Scholar
|
|
57
57
|
:target: https://scholar.google.com/citations?view_op=view_citation&hl=en&user=Mb7eYKYAAAAJ&citation_for_view=Mb7eYKYAAAAJ:u-x6o8ySG0sC
|
|
58
58
|
|
|
59
|
-
.. image:: https://socket.dev/api/badge/pypi/package/hbat/2.2.
|
|
59
|
+
.. image:: https://socket.dev/api/badge/pypi/package/hbat/2.2.11?artifact_id=py3-none-any-whl
|
|
60
60
|
:alt: Socket
|
|
61
|
-
:target: https://socket.dev/pypi/package/hbat/
|
|
61
|
+
:target: https://socket.dev/api/badge/pypi/package/hbat/2.2.11?artifact_id=py3-none-any-whl
|
|
62
62
|
|
|
63
63
|
.. image:: https://www.codefactor.io/repository/github/abhishektiwari/hbat/badge/main
|
|
64
64
|
:target: https://www.codefactor.io/repository/github/abhishektiwari/hbat/overview/main
|
|
@@ -17,5 +17,5 @@ __version__: str
|
|
|
17
17
|
__version_tuple__: VERSION_TUPLE
|
|
18
18
|
version_tuple: VERSION_TUPLE
|
|
19
19
|
|
|
20
|
-
__version__ = version = '2.2.
|
|
21
|
-
__version_tuple__ = version_tuple = (2, 2,
|
|
20
|
+
__version__ = version = '2.2.12'
|
|
21
|
+
__version_tuple__ = version_tuple = (2, 2, 12)
|
|
@@ -66,54 +66,110 @@ class TestSingleFileExports:
|
|
|
66
66
|
"""Create a mock analyzer with sample results."""
|
|
67
67
|
analyzer = Mock(spec=NPMolecularInteractionAnalyzer)
|
|
68
68
|
|
|
69
|
-
#
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
hb1.acceptor_residue = "A124ALA"
|
|
75
|
-
hb1.acceptor.name = "O"
|
|
76
|
-
hb1.distance = 2.8
|
|
77
|
-
hb1.angle = 2.79 # radians (~160 degrees)
|
|
78
|
-
hb1.donor_acceptor_distance = 3.2
|
|
79
|
-
hb1.bond_type = "N-H...O"
|
|
80
|
-
hb1.donor_acceptor_properties = "PBN-PBN"
|
|
81
|
-
hb1.get_backbone_sidechain_interaction = Mock(return_value="B-B")
|
|
69
|
+
# Create mock coordinate objects that support to_list()
|
|
70
|
+
def mock_coords(x, y, z):
|
|
71
|
+
coords = Mock()
|
|
72
|
+
coords.to_list.return_value = [x, y, z]
|
|
73
|
+
return coords
|
|
82
74
|
|
|
83
|
-
#
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
xb1.acceptor.name = "OD1"
|
|
90
|
-
xb1.distance = 3.5
|
|
91
|
-
xb1.angle = 2.62 # radians (~150 degrees)
|
|
92
|
-
xb1.bond_type = "C-Cl...O"
|
|
93
|
-
xb1.donor_acceptor_properties = "PSN-PSN"
|
|
94
|
-
xb1.get_backbone_sidechain_interaction = Mock(return_value="S-S")
|
|
75
|
+
# Create mock atom objects with proper attributes
|
|
76
|
+
def mock_atom(name, x=0.0, y=0.0, z=0.0):
|
|
77
|
+
atom = Mock()
|
|
78
|
+
atom.name = name
|
|
79
|
+
atom.coords = mock_coords(x, y, z)
|
|
80
|
+
return atom
|
|
95
81
|
|
|
96
|
-
#
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
82
|
+
# Create hydrogen bond object using a simple namespace class
|
|
83
|
+
class SimpleHBond:
|
|
84
|
+
def __init__(self):
|
|
85
|
+
self.donor_residue = "A123GLY"
|
|
86
|
+
self.donor = mock_atom("N", 1.0, 2.0, 3.0)
|
|
87
|
+
self.hydrogen = mock_atom("H", 1.1, 2.1, 3.1)
|
|
88
|
+
self.acceptor_residue = "A124ALA"
|
|
89
|
+
self.acceptor = mock_atom("O", 4.0, 5.0, 6.0)
|
|
90
|
+
self.distance = 2.8
|
|
91
|
+
self.angle = 2.79 # radians (~160 degrees)
|
|
92
|
+
self.donor_acceptor_distance = 3.2
|
|
93
|
+
self.bond_type = "N-H...O"
|
|
94
|
+
self.donor_acceptor_properties = "PBN-PBN"
|
|
95
|
+
|
|
96
|
+
def get_backbone_sidechain_interaction(self):
|
|
97
|
+
return "B-B"
|
|
98
|
+
|
|
99
|
+
hb1 = SimpleHBond()
|
|
100
|
+
|
|
101
|
+
# Create halogen bond object using a simple namespace class
|
|
102
|
+
class SimpleXBond:
|
|
103
|
+
def __init__(self):
|
|
104
|
+
self.halogen_residue = "A125TYR"
|
|
105
|
+
self.donor_residue = "A125TYR" # For compatibility
|
|
106
|
+
self.halogen = mock_atom("CL", 7.0, 8.0, 9.0)
|
|
107
|
+
self.acceptor_residue = "A126ASP"
|
|
108
|
+
self.acceptor = mock_atom("OD1", 10.0, 11.0, 12.0)
|
|
109
|
+
self.distance = 3.5
|
|
110
|
+
self.angle = 2.62 # radians (~150 degrees)
|
|
111
|
+
self.bond_type = "C-Cl...O"
|
|
112
|
+
self.donor_acceptor_properties = "PSN-PSN"
|
|
113
|
+
|
|
114
|
+
def get_backbone_sidechain_interaction(self):
|
|
115
|
+
return "S-S"
|
|
116
|
+
|
|
117
|
+
xb1 = SimpleXBond()
|
|
118
|
+
|
|
119
|
+
# Create pi interaction object using a simple namespace class
|
|
120
|
+
class SimplePiBond:
|
|
121
|
+
def __init__(self):
|
|
122
|
+
self.donor_residue = "A127LYS"
|
|
123
|
+
self.donor = mock_atom("NZ", 13.0, 14.0, 15.0)
|
|
124
|
+
self.hydrogen = mock_atom("HZ1", 13.1, 14.1, 15.1)
|
|
125
|
+
self.pi_residue = "A128PHE"
|
|
126
|
+
self.pi_center = mock_coords(16.0, 17.0, 18.0)
|
|
127
|
+
self.distance = 3.8
|
|
128
|
+
self.angle = 2.44 # radians (~140 degrees)
|
|
129
|
+
self.donor_acceptor_properties = "PSN-PSN"
|
|
130
|
+
|
|
131
|
+
def get_backbone_sidechain_interaction(self):
|
|
132
|
+
return "S-S"
|
|
133
|
+
|
|
134
|
+
def get_interaction_type_display(self):
|
|
135
|
+
return "NH-π"
|
|
136
|
+
|
|
137
|
+
pi1 = SimplePiBond()
|
|
107
138
|
|
|
108
|
-
#
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
139
|
+
# Create cooperativity chain with simple namespace classes
|
|
140
|
+
class SimpleChainInteraction:
|
|
141
|
+
def __init__(self):
|
|
142
|
+
self.interaction_type = "H-Bond"
|
|
143
|
+
self.distance = 2.8
|
|
144
|
+
self.angle = 2.79
|
|
145
|
+
self.bond_type = "N-H...O"
|
|
146
|
+
|
|
147
|
+
def get_donor_residue(self):
|
|
148
|
+
return "A123GLY"
|
|
149
|
+
|
|
150
|
+
def get_acceptor_residue(self):
|
|
151
|
+
return "A124ALA"
|
|
152
|
+
|
|
153
|
+
def get_donor_atom(self):
|
|
154
|
+
atom = Mock()
|
|
155
|
+
atom.name = "N"
|
|
156
|
+
return atom
|
|
157
|
+
|
|
158
|
+
def get_acceptor_atom(self):
|
|
159
|
+
atom = Mock()
|
|
160
|
+
atom.name = "O"
|
|
161
|
+
return atom
|
|
162
|
+
|
|
163
|
+
def get_interaction_type(self):
|
|
164
|
+
return self.interaction_type
|
|
112
165
|
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
166
|
+
class SimpleChain:
|
|
167
|
+
def __init__(self):
|
|
168
|
+
self.chain_length = 3
|
|
169
|
+
self.chain_type = "H-bond chain"
|
|
170
|
+
self.interactions = [SimpleChainInteraction(), SimpleChainInteraction(), SimpleChainInteraction()]
|
|
171
|
+
|
|
172
|
+
chain1 = SimpleChain()
|
|
117
173
|
|
|
118
174
|
analyzer.hydrogen_bonds = [hb1]
|
|
119
175
|
analyzer.halogen_bonds = [xb1]
|
|
@@ -205,42 +261,90 @@ class TestMultipleFileExports:
|
|
|
205
261
|
"""Create a mock analyzer with sample results."""
|
|
206
262
|
analyzer = Mock(spec=NPMolecularInteractionAnalyzer)
|
|
207
263
|
|
|
208
|
-
#
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
|
|
217
|
-
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
|
|
264
|
+
# Create mock coordinate objects that support to_list()
|
|
265
|
+
def mock_coords(x, y, z):
|
|
266
|
+
coords = Mock()
|
|
267
|
+
coords.to_list.return_value = [x, y, z]
|
|
268
|
+
return coords
|
|
269
|
+
|
|
270
|
+
# Create mock atom objects with proper attributes
|
|
271
|
+
def mock_atom(name, x=0.0, y=0.0, z=0.0):
|
|
272
|
+
atom = Mock()
|
|
273
|
+
atom.name = name
|
|
274
|
+
atom.coords = mock_coords(x, y, z)
|
|
275
|
+
return atom
|
|
276
|
+
|
|
277
|
+
# Create hydrogen bond object using a simple namespace class
|
|
278
|
+
class SimpleHBond:
|
|
279
|
+
def __init__(self):
|
|
280
|
+
self.donor_residue = "A123GLY"
|
|
281
|
+
self.donor = mock_atom("N", 1.0, 2.0, 3.0)
|
|
282
|
+
self.hydrogen = mock_atom("H", 1.1, 2.1, 3.1)
|
|
283
|
+
self.acceptor_residue = "A124ALA"
|
|
284
|
+
self.acceptor = mock_atom("O", 4.0, 5.0, 6.0)
|
|
285
|
+
self.distance = 2.8
|
|
286
|
+
self.angle = 2.79 # radians
|
|
287
|
+
self.donor_acceptor_distance = 3.2
|
|
288
|
+
self.bond_type = "N-H...O"
|
|
289
|
+
self.donor_acceptor_properties = "PBN-PBN"
|
|
290
|
+
|
|
291
|
+
def get_backbone_sidechain_interaction(self):
|
|
292
|
+
return "B-B"
|
|
293
|
+
|
|
294
|
+
hb1 = SimpleHBond()
|
|
295
|
+
|
|
296
|
+
# Create halogen bond object using a simple namespace class
|
|
297
|
+
class SimpleXBond:
|
|
298
|
+
def __init__(self):
|
|
299
|
+
self.halogen_residue = "A125TYR"
|
|
300
|
+
self.donor_residue = "A125TYR" # For compatibility
|
|
301
|
+
self.halogen = mock_atom("CL", 7.0, 8.0, 9.0)
|
|
302
|
+
self.acceptor_residue = "A126ASP"
|
|
303
|
+
self.acceptor = mock_atom("OD1", 10.0, 11.0, 12.0)
|
|
304
|
+
self.distance = 3.5
|
|
305
|
+
self.angle = 2.62 # radians
|
|
306
|
+
self.bond_type = "C-Cl...O"
|
|
307
|
+
self.donor_acceptor_properties = "PSN-PSN"
|
|
308
|
+
|
|
309
|
+
def get_backbone_sidechain_interaction(self):
|
|
310
|
+
return "S-S"
|
|
221
311
|
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
|
|
227
|
-
|
|
228
|
-
|
|
229
|
-
|
|
230
|
-
|
|
231
|
-
|
|
232
|
-
|
|
233
|
-
|
|
312
|
+
xb1 = SimpleXBond()
|
|
313
|
+
|
|
314
|
+
# Create cooperativity chain with simple namespace classes
|
|
315
|
+
class SimpleChainInteraction:
|
|
316
|
+
def __init__(self):
|
|
317
|
+
self.interaction_type = "H-Bond"
|
|
318
|
+
self.distance = 2.8
|
|
319
|
+
self.angle = 2.79
|
|
320
|
+
self.bond_type = "N-H...O"
|
|
321
|
+
|
|
322
|
+
def get_donor_residue(self):
|
|
323
|
+
return "A123GLY"
|
|
324
|
+
|
|
325
|
+
def get_acceptor_residue(self):
|
|
326
|
+
return "A124ALA"
|
|
327
|
+
|
|
328
|
+
def get_donor_atom(self):
|
|
329
|
+
atom = Mock()
|
|
330
|
+
atom.name = "N"
|
|
331
|
+
return atom
|
|
332
|
+
|
|
333
|
+
def get_acceptor_atom(self):
|
|
334
|
+
atom = Mock()
|
|
335
|
+
atom.name = "O"
|
|
336
|
+
return atom
|
|
337
|
+
|
|
338
|
+
def get_interaction_type(self):
|
|
339
|
+
return self.interaction_type
|
|
234
340
|
|
|
235
|
-
|
|
236
|
-
|
|
237
|
-
|
|
238
|
-
|
|
341
|
+
class SimpleChain:
|
|
342
|
+
def __init__(self):
|
|
343
|
+
self.chain_length = 3
|
|
344
|
+
self.chain_type = "H-bond chain"
|
|
345
|
+
self.interactions = [SimpleChainInteraction()]
|
|
239
346
|
|
|
240
|
-
|
|
241
|
-
interaction1.get_donor_residue = Mock(return_value="A123GLY")
|
|
242
|
-
interaction1.get_donor_atom = Mock(return_value=Mock(name="N"))
|
|
243
|
-
chain1.interactions = [interaction1]
|
|
347
|
+
chain1 = SimpleChain()
|
|
244
348
|
|
|
245
349
|
analyzer.hydrogen_bonds = [hb1]
|
|
246
350
|
analyzer.halogen_bonds = [xb1]
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|