Enable clang tidy/warnings for tests
[alexxy/gromacs.git] / src / gromacs / selection / tests / nbsearch.cpp
index 4e0c86802d0ee20518a30bf407c8f1e6a78d3680..e3afd50051d75036fd9316f6490fc8cd7636bf70 100644 (file)
@@ -168,11 +168,7 @@ class NeighborhoodSearchTestData
             const std::vector<RefPair>          &refPairs = testPositions_[testIndex].refPairs;
             std::vector<RefPair>::const_iterator foundRefPair
                 = std::lower_bound(refPairs.begin(), refPairs.end(), pair);
-            if (foundRefPair == refPairs.end() || foundRefPair->refIndex != pair.refIndex)
-            {
-                return false;
-            }
-            return true;
+            return !(foundRefPair == refPairs.end() || foundRefPair->refIndex != pair.refIndex);
         }
 
         // Return a tolerance that accounts for the magnitudes of the coordinates