From 1a3ccd4f0de0f32b49c8042ad7f9f8ccbc508ddf Mon Sep 17 00:00:00 2001
From: Scott Snyder <scott.snyder@cern.ch>
Date: Thu, 26 May 2016 19:40:56 +0200
Subject: [PATCH] 'Get tests working in cmake build.'
 (TrackParticleTruthAthenaPool-00-00-11)

	* Tagging TrackParticleTruthAthenaPool-00-00-11.
	* CMakeLists.txt: Get tests working in cmake build.
---
 .../TrackParticleTruthAthenaPool/CMakeLists.txt      | 12 ++++++++++++
 .../TrackParticleTruthAthenaPool/cmt/requirements    |  1 +
 .../share/TrackParticleTruthTPCnv_18.0.0_test.py     |  2 --
 3 files changed, 13 insertions(+), 2 deletions(-)

diff --git a/Reconstruction/TrackParticleTruthAthenaPool/CMakeLists.txt b/Reconstruction/TrackParticleTruthAthenaPool/CMakeLists.txt
index ae1cb21dae4c..1747f2ac317a 100644
--- a/Reconstruction/TrackParticleTruthAthenaPool/CMakeLists.txt
+++ b/Reconstruction/TrackParticleTruthAthenaPool/CMakeLists.txt
@@ -25,3 +25,15 @@ atlas_add_poolcnv_library( TrackParticleTruthAthenaPoolPoolCnv
 # Install files from the package:
 atlas_install_joboptions( share/*.py )
 
+# Set up (a) test(s) for the converter(s):
+if( IS_DIRECTORY ${CMAKE_SOURCE_DIR}/Database/AthenaPOOL/AthenaPoolUtilities )
+   set( AthenaPoolUtilitiesTest_DIR
+      ${CMAKE_SOURCE_DIR}/Database/AthenaPOOL/AthenaPoolUtilities/cmake )
+endif()
+find_package( AthenaPoolUtilitiesTest )
+
+if( ATHENAPOOLUTILITIESTEST_FOUND )
+  run_tpcnv_test( TrackParticleTruthTPCnv_18.0.0   AOD-18.0.0-full )
+else()
+   message( WARNING "Couldn't find AthenaPoolUtilitiesTest. No test(s) set up." )
+endif()   
diff --git a/Reconstruction/TrackParticleTruthAthenaPool/cmt/requirements b/Reconstruction/TrackParticleTruthAthenaPool/cmt/requirements
index d0f848307218..d6d885e4872c 100755
--- a/Reconstruction/TrackParticleTruthAthenaPool/cmt/requirements
+++ b/Reconstruction/TrackParticleTruthAthenaPool/cmt/requirements
@@ -32,3 +32,4 @@ apply_pattern athenarun_test \
    options="TrackParticleTruthAthenaPool/TrackParticleTruthTPCnv_18.0.0_test.py" \
    pre_script="${ATHENAPOOLUTILITIESROOT}/share/pre_tpcnvtest.sh TrackParticleTruthTPCnv_18.0.0" \
    post_script="${ATHENAPOOLUTILITIESROOT}/share/post_tpcnvtest.sh TrackParticleTruthTPCnv_18.0.0"
+
diff --git a/Reconstruction/TrackParticleTruthAthenaPool/share/TrackParticleTruthTPCnv_18.0.0_test.py b/Reconstruction/TrackParticleTruthAthenaPool/share/TrackParticleTruthTPCnv_18.0.0_test.py
index 8e672d9158e5..fae2bbfb4195 100644
--- a/Reconstruction/TrackParticleTruthAthenaPool/share/TrackParticleTruthTPCnv_18.0.0_test.py
+++ b/Reconstruction/TrackParticleTruthAthenaPool/share/TrackParticleTruthTPCnv_18.0.0_test.py
@@ -10,8 +10,6 @@ keys = [
     'TrackParticleTruthCollection',
          ]
 
-from AthenaCommon.JobProperties import jobproperties
-jobproperties.Global.DetDescrVersion = 'ATLAS-GEO-10-00-00'
 #noMuon = True
 #noID = True
 
-- 
GitLab