-
Notifications
You must be signed in to change notification settings - Fork 22
Implementation of enhanced stereochemistry #185
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Changes from 8 commits
Commits
Show all changes
52 commits
Select commit
Hold shift + click to select a range
d6dc293
Added unit test prototype for testing OutputINCHI_StereoLayer
cm-beilstein e5f4403
Added new unit-tests
cm-beilstein 4b8e52b
Merge branch 'refactor_main' into enh_stereo
cm-beilstein 3cff56f
Changed gtest test_suite names
cm-beilstein 321856d
Merge branch 'refactor_main' into enh_stereo
cm-beilstein bc49dca
New units for enh stereochemistry
cm-beilstein 0cf17b9
Added/corrected unit tests for enh stereo
cm-beilstein e0b38cb
Added unit tests for stereo-layer tags
cm-beilstein 2e9f95c
Added unit tests for m-layer
cm-beilstein 01ca153
Added doxygen comments
cm-beilstein ddd3c7a
Added unit tests and initial modification for enh stereo
cm-beilstein 892521a
Added functions for changing parities based on abs, rel, rac
cm-beilstein 65e5eb5
prototypes and unit-test for t and m-layer changes
cm-beilstein 0555b4f
added code for parity change (t+m-layer)
cm-beilstein 7988584
added unit test and param for enh stereochem
cm-beilstein 2d12b3b
fixed parity change bug for enhanced stereochemistry
cm-beilstein 0784a98
Removed inchi warning about enh stereo and added test for multiple fr…
cm-beilstein 9dacaa2
fixed s-layer duplication and unknown canonical atom mapping
cm-beilstein 7c62770
Fixed enh stereochem, added more unit-tests and modified CMakeLists f…
cm-beilstein 5766fec
Adjusted assert to account for missing enh stereo chem message
cm-beilstein 4ddd959
added fix if no collection available, standard functionality will be …
cm-beilstein 7e2da23
added m-layer change to 0 if no abs center present
cm-beilstein 37ad158
changed m layer based on feedback (no abs)
cm-beilstein e6fb59c
Bugfix for mol v2 files
cm-beilstein 99628bc
changed InChI-Prefix to InChI=1B (beta)
cm-beilstein 2ca5281
added unit tests and doxygen for functions used in enhanced stereoche…
cm-beilstein 5886446
added unit test fix for log message in MakeINCHIFromMolfileText
cm-beilstein 556adde
bug when switching from debug and release...
cm-beilstein 7d1fde3
Fixed unit test for testing batch test_file_1 (sdf)
cm-beilstein 6f16320
changed directory
cm-beilstein 5cd2aa7
added another unit test for testing enh stereo grps stretching over 2…
cm-beilstein 8b07bff
added atropisomer test for enh stereo
cm-beilstein 04a1c5b
added flags for gcov: needs to be run with cmake -DCOVERAGE=ON -B CMa…
cm-beilstein cf6d7ce
fixed unit test for atropisomer in enh stereo
cm-beilstein 3fad65a
added 2 unit tests with faulty molblocks
cm-beilstein b4446a0
added code for handling empty data
cm-beilstein 0ecfdf3
changed comments
cm-beilstein 578ab2d
Merge branch 'dev' into enh_stereo
cm-beilstein 39f053b
Merge branch 'refactor_main' into enh_stereo
cm-beilstein d2fd2be
clean up unit test code
cm-beilstein abb99e9
Merge branch 'dev' into enh_stereo
cm-beilstein 114bd64
Merge branch 'dev' into enh_stereo
cm-beilstein 9d4f720
removed sorting of stereo groups by index
cm-beilstein 5e193b4
Release v1.07.5
JanCBrammer fdb33c4
changed sorting of stereo groups to first canonical atom number in st…
cm-beilstein 8e02c7d
Merge branch 'dev' into enh_stereo
cm-beilstein 5c55589
Added comments and minor clean up
cm-beilstein 801a93f
Merge branch 'dev' into enh_stereo
cm-beilstein d0e2798
Added unit test for same molecules with different AND group numbering
cm-beilstein bad9cf6
Fix for Release #68 test run (github action workflow)
cm-beilstein f63ffb0
Fix for Release [#68](https://github.com/IUPAC-InChI/InChI/issues/68)…
cm-beilstein faa56a8
Fix for Release [(https://github.com/IUPAC-InChI/InChI/issues/68)] te…
cm-beilstein File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,90 @@ | ||
| #include <gtest/gtest.h> | ||
| #include <gmock/gmock.h> | ||
| #include <unistd.h> | ||
| #include <sys/stat.h> | ||
| #include <fstream> | ||
| #include <filesystem> | ||
| #include <vector> | ||
|
|
||
| extern "C" | ||
| { | ||
| #include "../../../INCHI-1-SRC/INCHI_BASE/src/ichimake.c" | ||
| #include "../../../INCHI-1-SRC/INCHI_BASE/src/ichi_io.h" | ||
| } | ||
|
|
||
| TEST(test_ichimake, test_GetSp3RelRacAbs_none) | ||
| { | ||
|
|
||
| INChI inchi = {0}; | ||
| INChI_Stereo stereo = {0}; | ||
|
|
||
| stereo.nNumberOfStereoCenters = 0; | ||
|
|
||
| // pINChI->bDeleted | ||
| // Stereo->nCompInv2Abs | ||
| // 0: No inversion (structure unchanged by inversion) | ||
| // Positive integer (>0): Indicates inversion changes the structure (normal/absolute stereo) | ||
| // Negative integer (<0): Indicates inversion changes the structure (inverted/absolute stereo) | ||
|
|
||
| //int GetSp3RelRacAbs(const INChI* pINChI, INChI_Stereo* Stereo); | ||
|
|
||
| int result = GetSp3RelRacAbs(&inchi, &stereo); | ||
|
|
||
| EXPECT_EQ(result, SP3_NONE); | ||
|
|
||
| } | ||
|
|
||
| TEST(test_ichimake, test_GetSp3RelRacAbs_sp3) | ||
| { | ||
| INChI inchi = {0}; | ||
| INChI_Stereo stereo = {0}; | ||
|
|
||
| stereo.nNumberOfStereoCenters = 1; | ||
| stereo.nCompInv2Abs = 0; | ||
|
|
||
| int result = GetSp3RelRacAbs(&inchi, &stereo); | ||
|
|
||
| EXPECT_EQ(result, SP3_ONLY); | ||
| } | ||
|
|
||
| TEST(test_ichimake, test_GetSp3RelRacAbs_rel) | ||
| { | ||
| INChI inchi = {0}; | ||
| INChI_Stereo stereo = {0}; | ||
|
|
||
| inchi.nFlags = INCHI_FLAG_REL_STEREO; | ||
| stereo.nNumberOfStereoCenters = 1; | ||
| stereo.nCompInv2Abs = 1; | ||
|
|
||
| int result = GetSp3RelRacAbs(&inchi, &stereo); | ||
|
|
||
| EXPECT_EQ(result, SP3_REL); | ||
| } | ||
|
|
||
| TEST(test_ichimake, test_GetSp3RelRacAbs_rac) | ||
| { | ||
| INChI inchi = {0}; | ||
| INChI_Stereo stereo = {0}; | ||
|
|
||
| inchi.nFlags = INCHI_FLAG_RAC_STEREO; | ||
| stereo.nNumberOfStereoCenters = 1; | ||
| stereo.nCompInv2Abs = 1; | ||
|
|
||
| int result = GetSp3RelRacAbs(&inchi, &stereo); | ||
|
|
||
| EXPECT_EQ(result, SP3_RAC); | ||
| } | ||
|
|
||
| TEST(test_ichimake, test_GetSp3RelRacAbs_abs) | ||
| { | ||
| INChI inchi = {0}; | ||
| INChI_Stereo stereo = {0}; | ||
|
|
||
| inchi.nFlags = 0x0111; | ||
| stereo.nNumberOfStereoCenters = 1; | ||
| stereo.nCompInv2Abs = 1; | ||
|
|
||
| int result = GetSp3RelRacAbs(&inchi, &stereo); | ||
|
|
||
| EXPECT_EQ(result, SP3_ABS); | ||
| } |
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.