diff --git a/roottest/CMakeLists.txt b/roottest/CMakeLists.txt index 31690991ee3ff..f5d75689a33b7 100644 --- a/roottest/CMakeLists.txt +++ b/roottest/CMakeLists.txt @@ -303,5 +303,8 @@ set(CMAKE_MACOSX_RPATH TRUE) # use RPATH for MacOSX include(RoottestCTest) include(SearchInstalledSoftwareRoottest) +ROOTTEST_COMPILE_MACRO(scripts/utils.cc + FIXTURES_SETUP roottest-scripts-utils-fixture) + message("-- Scanning subdirectories for tests...") ROOTTEST_ADD_TESTDIRS() diff --git a/roottest/root/tree/addresses/.rootrc b/roottest/root/tree/addresses/.rootrc deleted file mode 100644 index ef1466ce48926..0000000000000 --- a/roottest/root/tree/addresses/.rootrc +++ /dev/null @@ -1,2 +0,0 @@ -Rint.History: .root_hist -ACLiC.LinkLibs: 1 diff --git a/roottest/root/tree/addresses/BadBaseAddresses.ref b/roottest/root/tree/addresses/BadBaseAddresses.ref old mode 100755 new mode 100644 diff --git a/roottest/root/tree/addresses/CMakeLists.txt b/roottest/root/tree/addresses/CMakeLists.txt index e22041d8e3fd9..b8c5956511914 100644 --- a/roottest/root/tree/addresses/CMakeLists.txt +++ b/roottest/root/tree/addresses/CMakeLists.txt @@ -1,8 +1,255 @@ -#------------------------------------------------------------------------------- -# -# Placeholder file to translate the tests to the new CTest system. Meanwhile we -# define a CTest test that calls 'make' in ${CMAKE_CURRENT_SOURCE_DIR} -# -#------------------------------------------------------------------------------- -ROOTTEST_ADD_OLDTEST(LABELS longtest) +ROOTTEST_ADD_TESTDIRS() +ROOTTEST_COMPILE_MACRO(inherit.C + FIXTURES_SETUP root-tree-addresses-inherit-fixture) + +if(ClingWorkAroundMissingDynamicScope) + SET(_inherit_opts -e "(void)gROOT->ProcessLine(\".L inherit.C+g\")") +endif() + +ROOTTEST_ADD_TEST(inherit + MACRO runInherit.C + ROOTEXE_OPTS ${_inherit_opts} + OUTREF inheritTest.ref + FIXTURES_REQUIRED root-tree-addresses-inherit-fixture) + +ROOTTEST_COMPILE_MACRO(header.h + FIXTURES_SETUP root-tree-addresses-header-fixture) + +if(ClingWorkAroundMissingDynamicScope) + SET(_header_opts -e "(void)gROOT->ProcessLine(\".L header.h+g\")") +endif() + +ROOTTEST_ADD_TEST(header + MACRO runHeader.C + ROOTEXE_OPTS ${_header_opts} + OUTREF headerTest.ref + FIXTURES_REQUIRED root-tree-addresses-header-fixture) + +ROOTTEST_COMPILE_MACRO(clonesA_Event.cxx + FIXTURES_SETUP root-tree-addresses-clonesA_Event-fixture) + +if(ClingWorkAroundMissingDynamicScope) + SET(_clonesA_opts -e "(void)gROOT->ProcessLine(\".L clonesA_Event.cxx+\")") +endif() + +ROOTTEST_ADD_TEST(clonesA + MACRO clonesA_rw.C + ROOTEXE_OPTS ${_clonesA_opts} + FIXTURES_REQUIRED root-tree-addresses-clonesA_Event-fixture) + +ROOTTEST_COMPILE_MACRO(Embedded_load.C + FIXTURES_SETUP root-tree-addresses-Embedded_load-fixture) + +if(ClingWorkAroundMissingDynamicScope) + SET(_embedLoad_opts -e "(void)gROOT->ProcessLine(\".L Embedded_load.C+\")") +endif() + +ROOTTEST_ADD_TEST(embwrite + MACRO embwrite.C + ROOTEXE_OPTS ${_embedLoad_opts} + FIXTURES_REQUIRED root-tree-addresses-Embedded_load-fixture + FIXTURES_SETUP root-tree-addresses-embwrite-fixture) + +ROOTTEST_ADD_TEST(embread + MACRO embread.C + ROOTEXE_OPTS ${_embedLoad_opts} + OUTREF EmbeddedTest.ref + FIXTURES_REQUIRED root-tree-addresses-Embedded_load-fixture + root-tree-addresses-embwrite-fixture) + +# disable on Windows because relations_write.C compilation problem +# in any case test cannot be run on Windows because of sed usage +if(NOT MSVC OR win_broken_tests) + ROOTTEST_COMPILE_MACRO(relations_load.C + FIXTURES_SETUP root-tree-addresses-relations_load-fixture) + + ROOTTEST_COMPILE_MACRO(relations_read.C + FIXTURES_SETUP root-tree-addresses-relations_read-fixture) + + ROOTTEST_COMPILE_MACRO(relations_write.C + FIXTURES_SETUP root-tree-addresses-relations_write-fixture) + + SET(_relations_opts -e "(void)gROOT->ProcessLine(\".L relations_load.C+\")" + -e "(void)gROOT->ProcessLine(\".L relations_write.C+\")" + -e "(void)gROOT->ProcessLine(\".L relations_read.C+\")") + + ROOTTEST_ADD_TEST(relations + MACRO relationsRun.C + ROOTEXE_OPTS ${_relations_opts} + OUTREF relationsTest.ref + OUTCNVCMD sed -e "s|File Size =.*\\*||g" + FIXTURES_REQUIRED root-tree-addresses-relations_load-fixture + root-tree-addresses-relations_read-fixture + root-tree-addresses-relations_write-fixture) +endif() + +# disable on Windows because of problem with running same macro twice +if(NOT MSVC OR win_broken_tests) + ROOTTEST_ADD_TEST(merging + MACRO runmerging.C + OUTREF merging.ref) +endif() + +ROOTTEST_COMPILE_MACRO(iobug.C + FIXTURES_SETUP root-tree-addresses-iobug-fixture) + +ROOTTEST_ADD_TEST(iobug + MACRO runiobug.C + ROOTEXE_OPTS -e "(void)gSystem->Load(\"../../../utils_cc\")" + OUTREF iobug.ref + FIXTURES_REQUIRED root-tree-addresses-iobug-fixture roottest-scripts-utils-fixture) + +ROOTTEST_COMPILE_MACRO(userClass.C + FIXTURES_SETUP root-tree-addresses-userClass-fixture) + +ROOTTEST_COMPILE_MACRO(treeBranch.C + FIXTURES_SETUP root-tree-addresses-treeBranch-fixture) + +if(ClingWorkAroundMissingUnloading) + set(_treeBranch_ref treeBranch.ref-missingUnloading) +else() + set(_treeBranch_ref treeBranch.ref) +endif() + +ROOTTEST_ADD_TEST(treeBranch + MACRO runtreeBranch.C + OUTREF ${_treeBranch_ref} + FIXTURES_REQUIRED root-tree-addresses-userClass-fixture + root-tree-addresses-treeBranch-fixture) + +ROOTTEST_COMPILE_MACRO(test_Persistency0.C + FIXTURES_SETUP root-tree-addresses-test_Persistency0-fixture) + +ROOTTEST_COMPILE_MACRO(test_Persistency1.C + FIXTURES_SETUP root-tree-addresses-test_Persistency1-fixture) + +ROOTTEST_COMPILE_MACRO(test_Persistency3.C + FIXTURES_SETUP root-tree-addresses-test_Persistency3-fixture) + +ROOTTEST_ADD_TEST(inheritAndOwn + MACRO runinheritAndOwn.C + OUTREF inheritAndOwn.ref + FIXTURES_REQUIRED root-tree-addresses-test_Persistency0-fixture + root-tree-addresses-test_Persistency3-fixture) + +ROOTTEST_ADD_TEST(BadBaseAddresses + MACRO runBadBaseAddresses.C + OUTREF BadBaseAddresses.ref + FIXTURES_REQUIRED root-tree-addresses-test_Persistency1-fixture) + +ROOTTEST_ADD_TEST(ursula + MACRO runursula.C + COPY_TO_BUILDDIR cmsursula.root + OUTREF ursula.ref) + +#disable on Windows while there are problem to compile ConfigRecord.cxx without building dictionary +#for some classes +if(NOT MSVC OR win_broken_tests) + ROOTTEST_COMPILE_MACRO(ConfigRecord.cxx + FIXTURES_SETUP root-tree-addresses-ConfigRecord-fixture) + + ROOTTEST_COMPILE_MACRO(sueloader.C + FIXTURES_SETUP root-tree-addresses-sueloader-fixture) + + if(ClingWorkAroundMissingDynamicScope) + SET(_sue_opts -e "(void)gROOT->ProcessLine(\".L sueloader.C+\")" + -e "(void)gROOT->ProcessLine(\".L ConfigRecord.cxx+\")") + endif() + + ROOTTEST_ADD_TEST(configtest + MACRO suetestwrt.C + ROOTEXE_OPTS ${_sue_opts} + OUTREF configtest.ref + FIXTURES_REQUIRED root-tree-addresses-ConfigRecord-fixture + root-tree-addresses-sueloader-fixture + FIXTURES_SETUP root-tree-addresses-configtest-fixture) + + ROOTTEST_ADD_TEST(suetest + MACRO suetestrd.C + ROOTEXE_OPTS ${_sue_opts} + OUTREF suetest.ref + FIXTURES_REQUIRED root-tree-addresses-ConfigRecord-fixture + root-tree-addresses-sueloader-fixture + root-tree-addresses-configtest-fixture) +endif() + +ROOTTEST_COMPILE_MACRO(JansEvent.C + FIXTURES_SETUP root-tree-addresses-JansEvent-fixture) + +ROOTTEST_ADD_TEST(Jantest + MACRO runJantest.C + COPY_TO_BUILDDIR janbug.root + OUTREF Jantest.ref + FIXTURES_REQUIRED root-tree-addresses-JansEvent-fixture) + +ROOTTEST_ADD_TEST(deepnest + MACRO rundeepnest.C+ + OUTREF deepnest.ref) + +ROOTTEST_ADD_TEST(baseString + MACRO runbaseString.C+ + OUTREF baseString.ref) + +ROOTTEST_ADD_TEST(prova + MACRO runprova.C + COPY_TO_BUILDDIR prova1.root prova2.root + OUTREF prova.ref) + +ROOTTEST_ADD_TEST(augertest + MACRO runaugertest.C + COPY_TO_BUILDDIR data/S_1_1004_qgsjet_100_1.KGrec.root + data/S_1_104_qgsjet_100_1.KGrec.root + OUTREF augertest.ref) + +ROOTTEST_ADD_TEST(longlong + MACRO runlonglong.C+ + OUTCNVCMD sed -e s:0x[0-9a-fA-F]*:0xRemoved:g + OUTREF longlong.ref) + +ROOTTEST_ADD_TEST(memleak + MACRO runmemleak.C+ + COPY_TO_BUILDDIR memleak.root + OUTREF memleak.ref) + +ROOTTEST_ADD_TEST(Leaflist + MACRO execLeaflist.C + COPY_TO_BUILDDIR leaflist.root + OUTREF execLeaflist.ref) + +ROOTTEST_ADD_TEST(twrite + MACRO assert_twrite.cxx+ + ERRREF assert_twrite.ref + FIXTURES_SETUP root-tree-addresses-twrite-fixture) + +ROOTTEST_COMPILE_MACRO(assert_tread.cxx + FIXTURES_SETUP root-tree-addresses-assert_tread-fixture) + +ROOTTEST_ADD_TEST(tread + MACRO assert_tread.cxx+ + ERRREF assert_tread.ref + FIXTURES_REQUIRED root-tree-addresses-twrite-fixture root-tree-addresses-assert_tread-fixture) + +ROOTTEST_ADD_TEST(ReuseTree + MACRO execReuseTree.C + OUTREF execReuseTree.ref) + +ROOTTEST_ADD_TEST(BranchObjSplit0 + MACRO execBranchObjSplit0.C + OUTREF execBranchObjSplit0.ref) + +ROOTTEST_ADD_TEST(CheckErrors + MACRO execCheckErrors.C + OUTREF execCheckErrors.ref) + +ROOTTEST_ADD_TEST(CMSobj + MACRO execCMSobj.cxx+ + OUTREF execCMSobj.ref) + +ROOTTEST_COMPILE_MACRO(jet.C + FIXTURES_SETUP root-tree-addresses-jet-fixture) + +ROOTTEST_ADD_TEST(Jet + MACRO runJet.C + OUTREF Jet.ref + FIXTURES_REQUIRED root-tree-addresses-jet-fixture) \ No newline at end of file diff --git a/roottest/root/tree/addresses/ConfigRecord.cxx b/roottest/root/tree/addresses/ConfigRecord.cxx index 146d9d3f8bb80..43a7341713565 100644 --- a/roottest/root/tree/addresses/ConfigRecord.cxx +++ b/roottest/root/tree/addresses/ConfigRecord.cxx @@ -1,7 +1,5 @@ #ifndef ConfigRecord_cxx -#ifdef ClingWorkAroundMultipleInclude #define ConfigRecord_cxx -#endif #include "ConfigRecord.h" diff --git a/roottest/root/tree/addresses/ConfigRecord.h b/roottest/root/tree/addresses/ConfigRecord.h index b7dd31db680df..c4b11940c8e0d 100644 --- a/roottest/root/tree/addresses/ConfigRecord.h +++ b/roottest/root/tree/addresses/ConfigRecord.h @@ -1,16 +1,19 @@ +#ifndef ConfigRecord_h +#define ConfigRecord_h #include "RecHeader.h" -#include "RecDataRecord.cxx" -#include "RecRecordImp.cxx" +#include "RecDataRecord.h" class ConfigRecord : public RecDataRecord { public: ConfigRecord() {} - ConfigRecord(const RecHeader& header) : RecDataRecord(header){} + ConfigRecord(const RecHeader& header) : RecDataRecord(header){} ~ConfigRecord() override {} ClassDefOverride(ConfigRecord,1) // ConfigRecord }; + +#endif diff --git a/roottest/root/tree/addresses/Context.cxx b/roottest/root/tree/addresses/Context.cxx index c59fddae7b1eb..c416f08c8c242 100644 --- a/roottest/root/tree/addresses/Context.cxx +++ b/roottest/root/tree/addresses/Context.cxx @@ -1,8 +1,7 @@ -#include -using namespace std; - #include "Context.h" +#include + ClassImp(Context) //_____________________________________________________________________________ @@ -10,8 +9,8 @@ void Context::Print(Option_t *) const { // Print this object - cout << "Context::Print " << endl; - cout << "Detector " << fDetector << " SimFlag " << fSimFlag - << " Time " << fTimeStamp << endl; + std::cout << "Context::Print " << std::endl; + std::cout << "Detector " << fDetector << " SimFlag " << fSimFlag + << " Time " << fTimeStamp << std::endl; } diff --git a/roottest/root/tree/addresses/Embedded_load.C b/roottest/root/tree/addresses/Embedded_load.C old mode 100755 new mode 100644 diff --git a/roottest/root/tree/addresses/JansEvent.C b/roottest/root/tree/addresses/JansEvent.C old mode 100755 new mode 100644 diff --git a/roottest/root/tree/addresses/JansEvent.h b/roottest/root/tree/addresses/JansEvent.h old mode 100755 new mode 100644 diff --git a/roottest/root/tree/addresses/Jet.ref b/roottest/root/tree/addresses/Jet.ref new file mode 100644 index 0000000000000..276dad3d82289 --- /dev/null +++ b/roottest/root/tree/addresses/Jet.ref @@ -0,0 +1,17 @@ + +Processing runJet.C... +In event 0 jet #0 value are correct 0,33,44,55,0 +In event 0 jet #1 value are correct 0,33,44,55,1 +In event 0 jet #2 value are correct 0,33,44,55,2 +In event 0 jet #3 value are correct 0,33,44,55,3 +In event 0 jet #4 value are correct 0,33,44,55,4 +In event 1 jet #0 value are correct 1,33,44,55,0 +In event 1 jet #1 value are correct 1,33,44,55,1 +In event 1 jet #2 value are correct 1,33,44,55,2 +In event 1 jet #3 value are correct 1,33,44,55,3 +In event 1 jet #4 value are correct 1,33,44,55,4 +In event 2 jet #0 value are correct 2,33,44,55,0 +In event 2 jet #1 value are correct 2,33,44,55,1 +In event 2 jet #2 value are correct 2,33,44,55,2 +In event 2 jet #3 value are correct 2,33,44,55,3 +In event 2 jet #4 value are correct 2,33,44,55,4 diff --git a/roottest/root/tree/addresses/RecDataRecord.h b/roottest/root/tree/addresses/RecDataRecord.h index 1230b786e14be..ad0d6eaf637f4 100644 --- a/roottest/root/tree/addresses/RecDataRecord.h +++ b/roottest/root/tree/addresses/RecDataRecord.h @@ -1,7 +1,7 @@ #ifndef RECDATARECORD_H #define RECDATARECORD_H -#include "RecRecordImp.h" +#include "RecRecordImp.cxx" template class RecDataRecord : public RecRecordImp { @@ -10,8 +10,8 @@ class RecDataRecord : public RecRecordImp { // ctors/dtor RecDataRecord() {} RecDataRecord(const T& header) : RecRecordImp(header) {} - virtual ~RecDataRecord() {} - + ~RecDataRecord() override {} + private: // data members @@ -20,4 +20,4 @@ class RecDataRecord : public RecRecordImp { }; #endif - + diff --git a/roottest/root/tree/addresses/RecRecordImp.cxx b/roottest/root/tree/addresses/RecRecordImp.cxx index f2f3ac5aa40ad..8e303bffbb061 100644 --- a/roottest/root/tree/addresses/RecRecordImp.cxx +++ b/roottest/root/tree/addresses/RecRecordImp.cxx @@ -1,16 +1,11 @@ #ifndef RecRecordImp_cxx -#ifdef ClingWorkAroundMultipleInclude #define RecRecordImp_cxx -#endif #include -using namespace std; #include "RecRecordImp.h" - - template void RecRecordImp::Print(Option_t* /* option */) const { // @@ -21,9 +16,9 @@ void RecRecordImp::Print(Option_t* /* option */) const { // Return: none. // // Contact: S. Kasahara - // + // - cout << "RecRecordImp::Print Header:" << endl; + std::cout << "RecRecordImp::Print Header:" << std::endl; fHeader.Print(); return; diff --git a/roottest/root/tree/addresses/assert_twrite.cxx b/roottest/root/tree/addresses/assert_twrite.cxx old mode 100755 new mode 100644 diff --git a/roottest/root/tree/addresses/buildEmbedded.C b/roottest/root/tree/addresses/buildEmbedded.C deleted file mode 100755 index d0287ceeb5263..0000000000000 --- a/roottest/root/tree/addresses/buildEmbedded.C +++ /dev/null @@ -1,3 +0,0 @@ -{ - if (!gSystem->CompileMacro("Embedded_load.C","k")) gApplication->Terminate(1); -} diff --git a/roottest/root/tree/addresses/buildHeader.C b/roottest/root/tree/addresses/buildHeader.C deleted file mode 100755 index 68b031dae8073..0000000000000 --- a/roottest/root/tree/addresses/buildHeader.C +++ /dev/null @@ -1,3 +0,0 @@ -{ - if (!gSystem->CompileMacro("header.h","k")) gApplication->Terminate(1); -} diff --git a/roottest/root/tree/addresses/buildInherit.C b/roottest/root/tree/addresses/buildInherit.C deleted file mode 100755 index c43d0439852f7..0000000000000 --- a/roottest/root/tree/addresses/buildInherit.C +++ /dev/null @@ -1,3 +0,0 @@ -{ - if (!gSystem->CompileMacro("inherit.C","k")) gApplication->Terminate(1); -} diff --git a/roottest/root/tree/addresses/cmsursula.root b/roottest/root/tree/addresses/cmsursula.root old mode 100755 new mode 100644 diff --git a/roottest/root/tree/addresses/converterIssues/.rootrc b/roottest/root/tree/addresses/converterIssues/.rootrc deleted file mode 100644 index ef1466ce48926..0000000000000 --- a/roottest/root/tree/addresses/converterIssues/.rootrc +++ /dev/null @@ -1,2 +0,0 @@ -Rint.History: .root_hist -ACLiC.LinkLibs: 1 diff --git a/roottest/root/tree/addresses/converterIssues/CMakeLists.txt b/roottest/root/tree/addresses/converterIssues/CMakeLists.txt new file mode 100644 index 0000000000000..d3b490518fba3 --- /dev/null +++ b/roottest/root/tree/addresses/converterIssues/CMakeLists.txt @@ -0,0 +1,28 @@ +ROOTTEST_GENERATE_DICTIONARY(ExtHit + ExtHit/ExtHitProjectHeaders.h + LINKDEF ExtHit/ExtHitLinkDef.h + SOURCES ExtHit/ExtHitProjectSource.cxx + NO_ROOTMAP NO_CXXMODULE + FIXTURES_SETUP root-tree-addresses-convertIssues-ExtHit-fixture) + +target_link_libraries(ExtHitlibgen Physics) + +ROOTTEST_ADD_TEST(ROOT8794 + MACRO execROOT8794.C + OUTREF execROOT8794.ref + COPY_TO_BUILDDIR belle2-ROOT-8794.root + FIXTURES_REQUIRED root-tree-addresses-convertIssues-ExtHit-fixture) + +ROOTTEST_COMPILE_MACRO(execWriter.cxx + FIXTURES_SETUP root-tree-addresses-convertIssues-execWriterCompile-fixture) + +ROOTTEST_ADD_TEST(Writer + MACRO execWriter.cxx+ + OUTREF execWriter.ref + FIXTURES_REQUIRED root-tree-addresses-convertIssues-execWriterCompile-fixture + FIXTURES_SETUP root-tree-addresses-convertIssues-Writer-fixture) + +ROOTTEST_ADD_TEST(Reader + MACRO execReader.cxx+ + OUTREF execReader.ref + FIXTURES_REQUIRED root-tree-addresses-convertIssues-Writer-fixture) diff --git a/roottest/root/tree/addresses/converterIssues/ExtHit/MAKEP b/roottest/root/tree/addresses/converterIssues/ExtHit/MAKEP deleted file mode 100755 index 0a22ef88bb6a5..0000000000000 --- a/roottest/root/tree/addresses/converterIssues/ExtHit/MAKEP +++ /dev/null @@ -1,2 +0,0 @@ -rootcint -f ExtHitProjectDict.cxx -I$ROOTSYS/include -I"/opt/build/root_builds/rootcling.debug/etc" -I"/opt/build/root_builds/rootcling.debug/etc/cling" -I"/opt/build/root_builds/rootcling.debug/include" -I"/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/../include/c++/v1" -I"/Users/pcanal/root_working/code/rootcling" ExtHitProjectHeaders.h ExtHitLinkDef.h -cd . ; clang++ -c -g -m64 -std=c++11 -stdlib=libc++ -pipe -W -Woverloaded-virtual -fsigned-char -fno-common -pthread -Werror -I$ROOTSYS/include -I"/opt/build/root_builds/rootcling.debug/etc" -I"/opt/build/root_builds/rootcling.debug/etc/cling" -I"/opt/build/root_builds/rootcling.debug/include" -I"/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/../include/c++/v1" -I"/Users/pcanal/root_working/code/rootcling" -IExtHit ExtHitProjectSource.cxx ; clang++ ExtHitProjectSource.o -dynamiclib -single_module -Wl,-dead_strip_dylibs -g -m64 -mmacosx-version-min=10.12 -stdlib=libc++ -Wl,-rpath,@loader_path/../lib /opt/build/root_builds/rootcling.debug/lib/libCore.so /opt/build/root_builds/rootcling.debug/lib/libRint.so /usr/lib/libz.1.dylib /usr/lib/libsqlite3.dylib /usr/lib/libxml2.2.dylib /usr/lib/libnetwork.dylib /usr/lib/libenergytrace.dylib /usr/lib/libpcap.A.dylib /usr/lib/libcoretls.dylib /usr/lib/libcoretls_cfhelpers.dylib /usr/lib/libxar.1.dylib /usr/lib/libbz2.1.0.dylib /usr/lib/liblzma.5.dylib /usr/lib/libarchive.2.dylib /usr/lib/libmecabra.dylib /usr/lib/libcompression.dylib /usr/lib/libiconv.2.dylib /usr/lib/libheimdal-asn1.dylib /usr/lib/libmarisa.dylib /usr/lib/libChineseTokenizer.dylib /usr/lib/libcmph.dylib /usr/lib/libxslt.1.dylib /usr/lib/libScreenReader.dylib /usr/lib/libate.dylib /usr/lib/libFosl_dynamic.dylib /opt/build/root_builds/rootcling.debug/lib/libRIO.so /opt/build/root_builds/rootcling.debug/lib/libThread.so /opt/build/root_builds/rootcling.debug/lib/libCling.so /usr/lib/libncurses.5.4.dylib /opt/build/root_builds/rootcling.debug/lib/libMathCore.so /opt/build/root_builds/rootcling.debug/lib/libPhysics.so /opt/build/root_builds/rootcling.debug/lib/libMatrix.so /opt/build/root_builds/rootcling.debug/lib/libTree.so /opt/build/root_builds/rootcling.debug/lib/libNet.so -o ExtHit.so diff --git a/roottest/root/tree/addresses/converterIssues/Makefile b/roottest/root/tree/addresses/converterIssues/Makefile deleted file mode 100644 index 1de7325deced5..0000000000000 --- a/roottest/root/tree/addresses/converterIssues/Makefile +++ /dev/null @@ -1,83 +0,0 @@ -# This is a template for all makefiles. - -#Set the list of files to be deleted by clean (Targets can also be specified).: -CLEAN_TARGETS += $(ALL_LIBRARIES) *.log *.clog test_file.root \ - ExtHit/ExtHit.* ExtHit/*.$(ObjSuf) ExtHit/*.pcm ExtHit/*.log ExtHit/ExtHitProjectDict* - - -# Set the list of target to make while testing. By default, mytest is the -# only target added. If the name of the target is changed in the rules then -# the name should be changed accordingly in this list. - -TEST_TARGETS += mytest - -# Search for Rules.mk in roottest/scripts -# Algorithm: Find the current working directory and remove everything after -# '*roottest/'. Append the path for Rules.mk from within roottest, which -# should be 'scripts/Rules.mk'. The roottest path is saved in the -# ROOTTEST_HOME variable for use by the SUBDIRECTORIES variable and is -# exported to eliminate the overhead of findding the path again during -# recursive calls of gmake. -# Since all makefiles should be under roottest or one of its -# subdirectories and all recursions of gmake are called by -# 'cd [DIR]; gmake ...' -# this algorithm should not fail in finding /roottest/ in the -# current working directory. -# Issues: This algorithm will fail if a makefile is called from outside the -# roottest folder, as in executing 'gmake -f ~/roottest/Makefile' from -# the home directory. - -ifeq ($(strip $(ROOTTEST_HOME)),) - export ROOTTEST_HOME := $(shell git rev-parse --show-toplevel)/roottest/ - ifeq ($(strip $(ROOTTEST_HOME)),) - export ROOTTEST_HOME := $(shell expr $(CURDIR) : '\(.*/roottest/\)') - endif - ifeq ($(strip $(ROOTTEST_HOME)),) - $(error The head of roottest was not found. Set ROOTTEST_HOME) - endif -endif - -include $(ROOTTEST_HOME)/scripts/Rules.mk - - -# The name of this target should be changed according to the test being run. Any name changes -# should also be reflected in the TEST_TARGETS variable above. - -mytest: - $(CMDECHO) echo mytest > /dev/null - - -# Outputs a message if the FAIL variable is null - -testWithFailure: -ifeq ($(FAIL),) - $(WarnFailTest) -endif - - -# Remember that sometest.log can be made automatically from -# from runsometest.C -# This target attempts to create a log file (which should be the output of running the test), and -# compares its output with a prebuilt reference file. The reference file should be copied from -# the log files produced during what is considered a successful run of the test. The testWithDiff -# files should be renamed according to the test being run. -# By default the TestDiff variable is set to compare the .log and .ref files -# To run a diff and ignore whitespacing use $(TestDiffW) - -testWithDiff: testWithDiff.log testWithDiff.ref - $(TestDiff) - -execReader.clog: execWriter.success - - - - -ExtHit/ExtHitProjectDict.$(ObjSuf) ExtHit/ExtHitProjectSource.$(ObjSuf): $(ROOTCORELIBS) - -ExtHit/ExtHitProjectDict.cxx: ExtHit/ExtHitLinkDef.h - $(CMDECHO) cd ExtHit; rootcint -f ExtHitProjectDict.cxx ExtHitProjectHeaders.h ExtHitLinkDef.h - -ExtHit/ExtHit.$(DllSuf): ExtHit/ExtHitProjectDict.$(ObjSuf) ExtHit/ExtHitProjectSource.$(ObjSuf) $(ROOT_LOC)/lib/libPhysics.so - $(BuildFromObjs) - -execROOT8794.log: ExtHit/ExtHit.$(DllSuf) diff --git a/roottest/root/tree/addresses/converterIssues/execROOT8794.C b/roottest/root/tree/addresses/converterIssues/execROOT8794.C index 84a0e272dd8f4..ae37f754e0661 100644 --- a/roottest/root/tree/addresses/converterIssues/execROOT8794.C +++ b/roottest/root/tree/addresses/converterIssues/execROOT8794.C @@ -1,4 +1,4 @@ -R__LOAD_LIBRARY(ExtHit/ExtHit) +R__LOAD_LIBRARY(ExtHit) void execROOT8794() { @@ -53,5 +53,5 @@ void trim() { TFile *outfile = TFile::Open("b2.root","RECREATE"); TTree *outtree = tree->CloneTree(-1); outfile->Write(); - + } diff --git a/roottest/root/tree/addresses/janbug.root b/roottest/root/tree/addresses/janbug.root old mode 100755 new mode 100644 diff --git a/roottest/root/tree/addresses/memleak.root b/roottest/root/tree/addresses/memleak.root old mode 100755 new mode 100644 diff --git a/roottest/root/tree/addresses/merging.C b/roottest/root/tree/addresses/merging.C old mode 100755 new mode 100644 diff --git a/roottest/root/tree/addresses/relationsRun.C b/roottest/root/tree/addresses/relationsRun.C index 4a68db2c6f8ca..0f55f74ec017f 100644 --- a/roottest/root/tree/addresses/relationsRun.C +++ b/roottest/root/tree/addresses/relationsRun.C @@ -1,8 +1,8 @@ { -if (!gSystem->CompileMacro("relations_load.C","k")) gApplication->Terminate(1); -if (!gSystem->CompileMacro("relations_write.C","k")) gApplication->Terminate(1); -if (!gSystem->CompileMacro("relations_read.C","k")) gApplication->Terminate(1); +// if (!gSystem->CompileMacro("relations_load.C","k")) gApplication->Terminate(1); +// if (!gSystem->CompileMacro("relations_write.C","k")) gApplication->Terminate(1); +// if (!gSystem->CompileMacro("relations_read.C","k")) gApplication->Terminate(1); #ifdef ClingWorkAroundMissingDynamicScope gROOT->ProcessLine("Write(true); Read(true);"); diff --git a/roottest/root/tree/addresses/rootlogon.C b/roottest/root/tree/addresses/rootlogon.C deleted file mode 100644 index 18731d00b2e54..0000000000000 --- a/roottest/root/tree/addresses/rootlogon.C +++ /dev/null @@ -1,38 +0,0 @@ -{ - TString roottest_home = gSystem->Getenv("ROOTTEST_HOME"); - if (roottest_home == "") { - roottest_home = gSystem->pwd(); - Int_t pos = roottest_home.Index("/roottest/"); - if (pos==TString::kNPOS) { - pos = roottest_home.Index("\\roottest\\"); - if (pos!=TString::kNPOS) { - Int_t next = pos; - while (next != TString::kNPOS) { - pos = next; - next = roottest_home.Index("\\roottest\\",pos+1); - } - pos += strlen("\\roottest\\"); - } else { - printf("ERROR in rootlogon.C: cannot determine ROOTTEST_HOME!\n" - "Please rename the roottest root directory, it should be called \"roottest\"\n"); - exit(1); - } - } else { - Int_t next = pos; - while (next != TString::kNPOS) { - pos = next; - next = roottest_home.Index("/roottest/",pos+1); - } - pos += strlen("/roottest/"); - } - if (pos!=TString::kNPOS) { - roottest_home.Remove(pos); - } - } - if (!roottest_home.EndsWith("/")) { - roottest_home += "/"; - } - { - gROOT->ProcessLine(Form(".L %sscripts/utils.cc+",roottest_home.Data())); - } -} diff --git a/roottest/root/tree/addresses/runHeader.C b/roottest/root/tree/addresses/runHeader.C old mode 100755 new mode 100644 diff --git a/roottest/root/tree/addresses/runJantest.C b/roottest/root/tree/addresses/runJantest.C old mode 100755 new mode 100644 diff --git a/roottest/root/tree/addresses/runaugertest.C b/roottest/root/tree/addresses/runaugertest.C old mode 100755 new mode 100644 index 78b8a66dff918..c33c0127e666f --- a/roottest/root/tree/addresses/runaugertest.C +++ b/roottest/root/tree/addresses/runaugertest.C @@ -14,58 +14,61 @@ gStyle->SetLabelSize(0.04,"Y"); gStyle->SetTitleBorderSize(0); gStyle->SetTitleX(0.1); - + Int_t ncols,Eye,Run,Event; Int_t nlines = 0; - + #ifdef ClingWorkAroundProxyConfusion gInterpreter->GenerateDictionary("map","map"); #endif - + //*************************************// TChain *chain1 = new TChain("recData"); - chain1->Add("data/S_1*.root"); - chain1->Add("data/S_2*.root"); - chain1->Add("data/S_3*.root"); - chain1->Add("data/S_4*.root"); - chain1->Add("data/S_5*.root"); - + + chain1->Add("S_1*.root"); + + // chain1->Add("data/S_1*.root"); + // chain1->Add("data/S_2*.root"); + // chain1->Add("data/S_3*.root"); + // chain1->Add("data/S_4*.root"); + // chain1->Add("data/S_5*.root"); + // chain1->Add("/data/data_augerobserver_v2/simulations/prot_qgs/S_1*.root"); // chain1->Add("/data/data_augerobserver_v2/simulations/prot_qgs/S_2*.root"); // chain1->Add("/data/data_augerobserver_v2/simulations/prot_qgs/S_3*.root"); // chain1->Add("/data/data_augerobserver_v2/simulations/prot_qgs/S_4*.root"); // chain1->Add("/data/data_augerobserver_v2/simulations/prot_qgs/S_5*.root"); - + //chain1->Add("/data/data_augerobserver_v2/simulations/iron_qgs/S_1*.root"); //chain1->Add("/data/data_augerobserver_v2/simulations/iron_qgs/S_2*.root"); //chain1->Add("/data/data_augerobserver_v2/simulations/iron_qgs/S_3*.root"); //chain1->Add("/data/data_augerobserver_v2/simulations/iron_qgs/S_4*.root"); //chain1->Add("/data/data_augerobserver_v2/simulations/iron_qgs/S_5*.root"); - + // chain1->Draw("event.fGenShower.fEnergy") - - - + + + TCut pixelcut = "event.fFDEvents.fFdRecPixel.fnPixel>=6"; - - TCut profchisqcut = "((event.fFDEvents.fFdRecShower.fGHChi2/event.fFDEvents.fFdRecShower.fGHNdf)<6)"; - + + TCut profchisqcut = "((event.fFDEvents.fFdRecShower.fGHChi2/event.fFDEvents.fFdRecShower.fGHNdf)<6)"; + TCut hybridflagcut1 = "(abs(event.fFDEvents.fFdRecGeometry.fSDFDdT<200))"; - + TCut hybridflagcut2 = "(event.fFDEvents.fFdRecGeometry.fTimeFitFDChi2/(event.fFDEvents.fFdRecPixel.fnPixel-3)<5)"; - + TCut hybridflagcut3 = "(event.fFDEvents.fFdRecGeometry.fAxisDist<2000)"; - + TCut chkovfraccut = "(event.fFDEvents.fFdRecShower.fChkovFrac<50)"; - + TCut xtrackcut1 = "((event.fFDEvents.fFdRecShower.fXTrackMin+30)Draw(); XmaxVsXlow->Divide(3,2); XmaxVsXlow->SetGrid(); - + XmaxVsXlow->cd(1); #ifdef ClingWorkAroundMissingDynamicScope TPad *XmaxVsXlow_1; @@ -95,9 +98,9 @@ Xlow170->SetYTitle("Xmax(g/cm^{2}) "); Xlow170->SetXTitle("XFOVMin(g/cm^{2}) "); Xlow170->SetTitle("17.25#leqLogE<17.5"); - + chain1->Draw("event.fFDEvents.fFdRecShower.fXFOVMin",fdenergycut1 && xmaxcut0 && thetacut && pixelcut && profchisqcut && hybridflagcut1 && hybridflagcut2 && hybridflagcut3 && chkovfraccut && xtrackcut1 && xtrackcut2 && rp_cut && chi0_cut && BasicAntiBias_sim,""); - + XmaxVsXlow->Modified(); XmaxVsXlow->Update(); } diff --git a/roottest/root/tree/addresses/runbaseString.C b/roottest/root/tree/addresses/runbaseString.C old mode 100755 new mode 100644 diff --git a/roottest/root/tree/addresses/runbaseString.h b/roottest/root/tree/addresses/runbaseString.h old mode 100755 new mode 100644 diff --git a/roottest/root/tree/addresses/runmemleak.C b/roottest/root/tree/addresses/runmemleak.C old mode 100755 new mode 100644 diff --git a/roottest/root/tree/addresses/suetestrd.C b/roottest/root/tree/addresses/suetestrd.C index f64b88d61c2fe..33082bea6eda9 100644 --- a/roottest/root/tree/addresses/suetestrd.C +++ b/roottest/root/tree/addresses/suetestrd.C @@ -2,8 +2,8 @@ // usage: root[0] .x testrd.C #ifndef ClingWorkAroundMissingDynamicScope - gSystem->Load("sueloader_C"); - gSystem->Load("ConfigRecord_cxx"); + // gSystem->Load("sueloader_C"); + // gSystem->Load("ConfigRecord_cxx"); #endif ConfigRecord* record = 0; diff --git a/roottest/root/tree/addresses/suetestwrt.C b/roottest/root/tree/addresses/suetestwrt.C index 2b30242397e7c..86d5bfa484125 100644 --- a/roottest/root/tree/addresses/suetestwrt.C +++ b/roottest/root/tree/addresses/suetestwrt.C @@ -2,10 +2,10 @@ // usage: root[0] .x testwrt.C #ifndef ClingWorkAroundMissingDynamicScope - gSystem -> Load("sueloader_C"); - gSystem -> Load("ConfigRecord_cxx"); + // gSystem -> Load("sueloader_C"); + // gSystem -> Load("ConfigRecord_cxx"); #endif - + auto f = new TFile("configtest.root","RECREATE"); auto t = new TTree("Config","Config Test"); @@ -17,7 +17,7 @@ for ( int i = 0; i < 5; i++ ) { Context context(1,2,3); RecHeader hdr(context); record = new ConfigRecord(hdr); - t->SetBranchAddress("ConfigRecord",&record); + t->SetBranchAddress("ConfigRecord",&record); Int_t nbytes = t -> Fill(); cout << "Filled entry " << i << " with " << nbytes << " bytes." << endl; record -> Print(); diff --git a/roottest/root/tree/addresses/test_Persistency0.C b/roottest/root/tree/addresses/test_Persistency0.C old mode 100755 new mode 100644 diff --git a/roottest/root/tree/addresses/treeBranch.ref-missingUnloading b/roottest/root/tree/addresses/treeBranch.ref-missingUnloading index e951c6a58b636..21d7296cae453 100644 --- a/roottest/root/tree/addresses/treeBranch.ref-missingUnloading +++ b/roottest/root/tree/addresses/treeBranch.ref-missingUnloading @@ -4,24 +4,24 @@ Warning in : The actual TClass corresponding to the object provid The object will be truncated down to its TopLevel part ****************************************************************************** *Tree : : * -*Entries : 0 : Total = 3346 bytes File Size = 0 * +*Entries : 0 : Total = 3423 bytes File Size = 0 * * : : Tree compression factor = 1.00 * ****************************************************************************** *Branch :one * *Entries : 0 : BranchElement (see below) * *............................................................................* *Br 0 :t : Int_t * -*Entries : 0 : Total Size= 462 bytes One basket in memory * +*Entries : 0 : Total Size= 473 bytes One basket in memory * *Baskets : 0 : Basket Size= 32000 bytes Compression= 1.00 * *............................................................................* *Br 1 :b : Int_t * -*Entries : 0 : Total Size= 462 bytes One basket in memory * +*Entries : 0 : Total Size= 473 bytes One basket in memory * *Baskets : 0 : Basket Size= 32000 bytes Compression= 1.00 * *............................................................................* *Branch :missing * *Entries : 0 : BranchElement (see below) * *............................................................................* *Br 2 :t : Int_t * -*Entries : 0 : Total Size= 462 bytes One basket in memory * +*Entries : 0 : Total Size= 473 bytes One basket in memory * *Baskets : 0 : Basket Size= 32000 bytes Compression= 1.00 * *............................................................................* diff --git a/roottest/root/tree/addresses/userClass.C b/roottest/root/tree/addresses/userClass.C index 4f7f8e35e35f1..75079830aaec4 100644 --- a/roottest/root/tree/addresses/userClass.C +++ b/roottest/root/tree/addresses/userClass.C @@ -1,10 +1,8 @@ #ifndef userClass_C -#ifdef ClingWorkAroundMultipleInclude #define userClass_C -#endif -class TopLevel { -public: +class TopLevel { +public: virtual ~TopLevel() {} int t; }; @@ -12,7 +10,6 @@ class BottomOne : public TopLevel { public: int b; }; -#endif // Expose this to the interpreter, even if the library already pulled // this header (with __ROOTCLING__ and thus without BottomMissing) into @@ -23,3 +20,5 @@ public: int c; }; #endif + +#endif diff --git a/roottest/root/tree/array/.rootrc b/roottest/root/tree/array/.rootrc deleted file mode 100644 index 6ebe75fd4ec5a..0000000000000 --- a/roottest/root/tree/array/.rootrc +++ /dev/null @@ -1 +0,0 @@ -Rint.History: .root_hist diff --git a/roottest/root/tree/array/CMakeLists.txt b/roottest/root/tree/array/CMakeLists.txt index 182629f9610bb..ba1f7ebbccd19 100644 --- a/roottest/root/tree/array/CMakeLists.txt +++ b/roottest/root/tree/array/CMakeLists.txt @@ -1,8 +1,21 @@ -#------------------------------------------------------------------------------- -# -# Placeholder file to translate the tests to the new CTest system. Meanwhile we -# define a CTest test that calls 'make' in ${CMAKE_CURRENT_SOURCE_DIR} -# -#------------------------------------------------------------------------------- - -ROOTTEST_ADD_OLDTEST() +ROOTTEST_ADD_TEST(StdArray + MACRO execStdArray.C + OUTREF execStdArray.ref) + +ROOTTEST_COMPILE_MACRO(TestObj.cpp + FIXTURES_SETUP root-tree-array-TestObj-fixture) + +if(ClingWorkAroundMissingDynamicScope) + set(_load_class -e "(void)gROOT->ProcessLine(\".L TestObj.cpp+\")") +endif() + +ROOTTEST_ADD_TEST(objArrayTest + ROOTEXE_OPTS ${_load_class} + MACRO runobjArrayTest.C + OUTREF objArrayTest.ref + FIXTURES_REQUIRED root-tree-array-TestObj-fixture) + +ROOTTEST_ADD_TEST(objArrayTest2 + MACRO run2.C + OUTREF objArrayTest2.ref + FIXTURES_REQUIRED root-tree-array-TestObj-fixture root-tree-array-save-fixture) diff --git a/roottest/root/tree/array/Makefile b/roottest/root/tree/array/Makefile deleted file mode 100644 index 9bc546e78272f..0000000000000 --- a/roottest/root/tree/array/Makefile +++ /dev/null @@ -1,50 +0,0 @@ -# This is a template for all makefile. - -#Set the list of files to be delete by clean: -CLEAN_TARGETS += $(ALL_LIBRARIES) test.root *.log - -#Set the list of target to make while testing -TEST_TARGETS += objArrayTest objArrayTest2 - -# adjust the location of Rules.mk as needed. -ifeq ($(strip $(ROOTTEST_HOME)),) - export ROOTTEST_HOME := $(shell git rev-parse --show-toplevel)/roottest/ - ifeq ($(strip $(ROOTTEST_HOME)),) - export ROOTTEST_HOME := $(shell expr $(CURDIR) : '\(.*/roottest/\)') - endif - ifeq ($(strip $(ROOTTEST_HOME)),) - $(error The head of roottest was not found. Set ROOTTEST_HOME) - endif -endif - -include $(ROOTTEST_HOME)/scripts/Rules.mk - -ifneq ($(ClingWorkAroundMissingDynamicScope),) -objArrayTest.log: CALLROOTEXE += -e 'gROOT->ProcessLine(".L TestObj.cpp+");' -endif - -objArrayTest.log: TestObj_cpp.$(DllSuf) - -objArrayTest: objArrayTest.log objArrayTest.ref - $(CMDECHO) diff -b objArrayTest.ref objArrayTest.log - -save_C.$(DllSuf) : save.C TestObj_cpp.$(DllSuf) - $(BuildWithLib) - -TestObj_cpp.$(DllSuf) : TestObj.h - -objArrayTest2.log: TestObj_cpp.$(DllSuf) save_C.$(DllSuf) - $(CMDECHO) $(CALLROOTEXE) -q -b -l run2.C 2>&1 | tee objArrayTest2full.log | grep -v ' at 0x' > $@ - -objArrayTest2: objArrayTest2.log - $(CMDECHO) diff -b objArrayTest2.ref objArrayTest2.log - -mytest: - $(CMDECHO) echo mytest > /dev/null - -testWithFailure: -ifeq ($(FAIL),) - $(WarnFailTest) -endif - - diff --git a/roottest/root/tree/array/TestObj.cpp b/roottest/root/tree/array/TestObj.cpp index d4199f8a96f77..7bb7535d212b1 100644 --- a/roottest/root/tree/array/TestObj.cpp +++ b/roottest/root/tree/array/TestObj.cpp @@ -4,6 +4,42 @@ #include "TestObj.h" +#include "TFile.h" +#include "TTree.h" ClassImp(Reconstruction) //const bool Reconstruction::gInitted = Reconstruction::StaticInit(); + + + + +void save() +{ + AllReconstructions* pRec = new AllReconstructions; + TFile* file = new TFile("test.root", "RECREATE"); + TTree* Tree = new TTree("TestTree", "Test"); + Tree->Branch("Main", "AllReconstructions", &pRec, 32000, 99); + pRec->Init(); + for (int i = 0; i < 10; ++i) { + pRec->Init(i); + Tree->Fill(); + }; + file->Write(); + pRec->print(); + + delete file; + file = 0; + Tree = 0; + + delete pRec; + pRec = 0; + + fprintf(stderr, "reloading\n"); + file = new TFile("test.root"); + TTree* tree = (TTree*) file->Get("TestTree"); + tree->SetBranchAddress("Main", &pRec); + tree->GetEntry(3); + pRec->print(); + // Disconnect the branch from the local variable. + tree->SetBranchAddress("Main", 0); +} diff --git a/roottest/root/tree/array/TestObj.h b/roottest/root/tree/array/TestObj.h index 41ad1399d7ec8..a6babd2a86369 100644 --- a/roottest/root/tree/array/TestObj.h +++ b/roottest/root/tree/array/TestObj.h @@ -21,11 +21,11 @@ class Particle { void Clear() { nt = 2; t[1] = t[0] = 1; } int print() { - fprintf(stderr,"Particle at 0x%p\n",this); + // fprintf(stderr,"Particle at 0x%p\n",this); fprintf(stderr," nt ==%d\n",nt); fprintf(stderr," t[0]==%d\n",t[0]); fprintf(stderr," t[1]==%d\n",t[1]); - return 0; + return 0; } }; // Particle @@ -44,13 +44,13 @@ class Reconstruction: public TObject { TObject::Clear(opt); } int print() { - fprintf(stderr,"Reconstruction at 0x%p\n",this); + // fprintf(stderr,"Reconstruction at 0x%p\n",this); fprintf(stderr," np==%d\n",np); p[0].print(); p[1].print(); return 0; } - + private: // static const bool gInitted; // static bool StaticInit() { Class()->IgnoreTObjectStreamer(); } @@ -70,7 +70,7 @@ class AllReconstructions { void Clear() { for (int i = 0; i < 6; ++i) r[i]->Clear(); } int print() { - fprintf(stderr,"AllReconstructions at 0x%p\n",this); + // fprintf(stderr,"AllReconstructions at 0x%p\n",this); for(int i = 0; i < 6; ++i) { Reconstruction *obj = (Reconstruction *)r[i]; obj->print(); @@ -80,4 +80,6 @@ class AllReconstructions { }; // AllReconostructions +extern void save(); + #endif // __TESTOBJ_H diff --git a/roottest/root/tree/array/run2.C b/roottest/root/tree/array/run2.C index 6090a111574de..0a7d62a7ba633 100644 --- a/roottest/root/tree/array/run2.C +++ b/roottest/root/tree/array/run2.C @@ -1,6 +1,5 @@ { gROOT->ProcessLine(".L TestObj.cpp+"); -gROOT->ProcessLine(".L save.C+"); #ifdef ClingWorkAroundMissingDynamicScope gROOT->ProcessLine("save();"); #else diff --git a/roottest/root/tree/array/save.C b/roottest/root/tree/array/save.C deleted file mode 100644 index 9b0b41168b7e3..0000000000000 --- a/roottest/root/tree/array/save.C +++ /dev/null @@ -1,40 +0,0 @@ -#include "TFile.h" -#include "TSystem.h" -#include "TestObj.h" -#include "TTree.h" - -void save() -{ - - //gROOT->ProcessLine(".L TestObj.cpp+"); - //gSystem->Load("TestObj.so"); - - AllReconstructions* pRec = new AllReconstructions; - TFile* file = new TFile("test.root", "RECREATE"); - TTree* Tree = new TTree("TestTree", "Test"); - Tree->Branch("Main", "AllReconstructions", &pRec, 32000, 99); - pRec->Init(); - for (int i = 0; i < 10; ++i) { - pRec->Init(i); - Tree->Fill(); - }; - file->Write(); - pRec->print(); - - delete file; - file = 0; - Tree = 0; - - delete pRec; - pRec = 0; - - fprintf(stderr, "reloading\n"); - file = new TFile("test.root"); - TTree* tree = (TTree*) file->Get("TestTree"); - tree->SetBranchAddress("Main", &pRec); - tree->GetEntry(3); - pRec->print(); - // Disconnect the branch from the local variable. - tree->SetBranchAddress("Main", 0); -} - diff --git a/roottest/root/treedraw/CMakeLists.txt b/roottest/root/treedraw/CMakeLists.txt index 152a24d555bee..d0e530f122b7e 100644 --- a/roottest/root/treedraw/CMakeLists.txt +++ b/roottest/root/treedraw/CMakeLists.txt @@ -1,6 +1,3 @@ -ROOTTEST_COMPILE_MACRO(${CMAKE_SOURCE_DIR}/roottest/scripts/utils.cc - FIXTURES_SETUP root-treedraw-utils-fixture) - ROOTTEST_ADD_TEST(create MACRO ${CMAKE_SOURCE_DIR}/tutorials/hsimple.C PASSRC 255 @@ -8,7 +5,7 @@ ROOTTEST_ADD_TEST(create ROOTTEST_ADD_TEST(simple MACRO runsimple.C - ROOTEXE_OPTS -e "(void)gSystem->Load(\"utils_cc\")" + ROOTEXE_OPTS -e "(void)gSystem->Load(\"../../utils_cc\")" COPY_TO_BUILDDIR hsimple.ps.ref OUTREF simple.ref - FIXTURES_REQUIRED root-treedraw-utils-fixture root-treedraw-create-fixture) + FIXTURES_REQUIRED roottest-scripts-utils-fixture root-treedraw-create-fixture)