Add unit tests for index groups in selections.
authorTeemu Murtola <teemu.murtola@gmail.com>
Wed, 1 May 2013 17:55:45 +0000 (20:55 +0300)
committerGerrit Code Review <gerrit@gerrit.gromacs.org>
Mon, 5 Aug 2013 04:16:59 +0000 (06:16 +0200)
commit54903092fe7d3b9dc88ab214d3e4d87f7efd9f18
treea9dc41bec2f87a82cf1da80b7af09cf97ef8214e
parentdecc828ab7b056e47ef4e6b5b699282ee9967ba1
Add unit tests for index groups in selections.

Add tests for using the "group" keyword in selections to select external
index groups, and in particular for directly providing an index group as
the selection value.

Fixed a master-only issue in handling the selection name in the latter
cases.  Also fixed master-only memory leaks and other issues in
gmx_ana_indexgrps_init().

Part of #651.

Change-Id: I0d908213f109ced9ab6708e55c6acf53371f6aa1
15 files changed:
src/gromacs/selection/indexutil.cpp
src/gromacs/selection/parser.cpp
src/gromacs/selection/parser.y
src/gromacs/selection/parsetree.cpp
src/gromacs/selection/selection.cpp
src/gromacs/selection/selection.h
src/gromacs/selection/selectioncollection.cpp
src/gromacs/selection/selelem.cpp
src/gromacs/selection/selelem.h
src/gromacs/selection/tests/refdata/SelectionCollectionDataTest_HandlesIndexGroupsInSelections.xml [new file with mode: 0644]
src/gromacs/selection/tests/refdata/SelectionCollectionDataTest_HandlesIndexGroupsInSelectionsDelayed.xml [new file with mode: 0644]
src/gromacs/selection/tests/refdata/SelectionCollectionDataTest_HandlesSelectionNames.xml [new file with mode: 0644]
src/gromacs/selection/tests/refdata/referencedata.xsl
src/gromacs/selection/tests/selectioncollection.cpp
src/gromacs/selection/tests/simple.ndx [new file with mode: 0644]