From: Teemu Murtola Date: Fri, 22 May 2015 10:45:31 +0000 (+0300) Subject: Merge release-5-0 into master X-Git-Url: http://biod.pnpi.spb.ru/gitweb/?a=commitdiff_plain;h=2926de7dfa1522bd97e9e6a2797b1e7d4955a177;p=alexxy%2Fgromacs.git Merge release-5-0 into master Conflicts: src/gromacs/selection/tests/selectioncollection.cpp Took both tests added in the different branches at the same location. Change-Id: I305dd8e37373c3f913b3e86d0ddb286926c3d0db --- 2926de7dfa1522bd97e9e6a2797b1e7d4955a177 diff --cc src/gromacs/selection/tests/selectioncollection.cpp index f17c17d2b3,6a40ad7462..8521a27d44 --- a/src/gromacs/selection/tests/selectioncollection.cpp +++ b/src/gromacs/selection/tests/selectioncollection.cpp @@@ -1128,47 -1087,16 +1154,57 @@@ TEST_F(SelectionCollectionDataTest, Han } + TEST_F(SelectionCollectionDataTest, HandlesEmptyReferenceForSame) + { + static const char * const selections[] = { + "same residue as none", + "same resname as none" + }; + runTest("simple.gro", selections); + } + + +TEST_F(SelectionCollectionDataTest, HandlesPositionModifiersForKeywords) +{ + static const char * const selections[] = { + "res_cog x > 2", + "name CB and res_cog y > 2.5" + }; + setFlags(TestFlags() | efTestEvaluation); + runTest("simple.gro", selections); +} + + +TEST_F(SelectionCollectionDataTest, HandlesPositionModifiersForMethods) +{ + static const char * const selections[] = { + "res_cog distance from cog of resnr 1 < 2", + "res_cog within 2 of cog of resnr 1" + }; + setFlags(TestFlags() | efTestEvaluation); + runTest("simple.gro", selections); +} + + +TEST_F(SelectionCollectionDataTest, HandlesKeywordOfPositions) +{ + static const char * const selections[] = { + "x < y of cog of resnr 2" + }; + setFlags(TestFlags() | efTestEvaluation); + runTest("simple.gro", selections); +} + +TEST_F(SelectionCollectionDataTest, HandlesKeywordOfPositionsInArithmetic) +{ + static const char * const selections[] = { + "x - y of cog of resnr 2 < 0" + }; + setFlags(TestFlags() | efTestEvaluation); + runTest("simple.gro", selections); +} + + TEST_F(SelectionCollectionDataTest, HandlesNumericComparisons) { static const char * const selections[] = {