diff --git a/cmake/modules/RootMacros.cmake b/cmake/modules/RootMacros.cmake index 5343b22edb18a..d2cd2eb0aba9f 100644 --- a/cmake/modules/RootMacros.cmake +++ b/cmake/modules/RootMacros.cmake @@ -2756,7 +2756,7 @@ macro(ROOTTEST_SETUP_MACROTEST) set(root_buildcmd ${ROOT_root_CMD} ${RootExeDefines} -q -l -b) # Compile macro, then add to CTest. - if(ARG_MACRO MATCHES "[.]C\\+" OR ARG_MACRO MATCHES "[.]cxx\\+") + if(ARG_MACRO MATCHES "[.]C\\+" OR ARG_MACRO MATCHES "[.]cxx\\+" OR ARG_MACRO MATCHES "[.]cpp\\+" OR ARG_MACRO MATCHES "[.]cc\\+") string(REPLACE "+" "" compile_name "${ARG_MACRO}") get_filename_component(realfp ${compile_name} REALPATH) @@ -2767,7 +2767,7 @@ macro(ROOTTEST_SETUP_MACROTEST) endif() # Add interpreted macro to CTest. - elseif(ARG_MACRO MATCHES "[.]C" OR ARG_MACRO MATCHES "[.]cxx") + elseif(ARG_MACRO MATCHES "[.]C" OR ARG_MACRO MATCHES "[.]cxx" OR ARG_MACRO MATCHES "[.]cpp" OR ARG_MACRO MATCHES "[.]cc") get_filename_component(realfp ${ARG_MACRO} REALPATH) if(DEFINED ARG_MACROARG) set(realfp "${realfp}(${ARG_MACROARG})") diff --git a/roottest/root/tree/branches/.rootrc b/roottest/root/tree/branches/.rootrc deleted file mode 100644 index 6ebe75fd4ec5a..0000000000000 --- a/roottest/root/tree/branches/.rootrc +++ /dev/null @@ -1 +0,0 @@ -Rint.History: .root_hist diff --git a/roottest/root/tree/branches/CMakeLists.txt b/roottest/root/tree/branches/CMakeLists.txt index 239d67bfd9c5c..10cbd25e8ec10 100644 --- a/roottest/root/tree/branches/CMakeLists.txt +++ b/roottest/root/tree/branches/CMakeLists.txt @@ -1,13 +1,116 @@ -#------------------------------------------------------------------------------- -# -# 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) - -# New tests follow - # ROOT-5983 ROOTTEST_ADD_TEST(initOffset - MACRO initOffset.C+) \ No newline at end of file + MACRO initOffset.C+) + +ROOTTEST_ADD_TEST(abc_rflx + COMMAND ${ROOT_genreflex_CMD} ${CMAKE_CURRENT_SOURCE_DIR}/abc.h -o abc_rflx.cpp + FIXTURES_SETUP root-tree-branches-abc-rflx-dict-fixture) + +ROOTTEST_COMPILE_MACRO(abc.h + FIXTURES_SETUP root-tree-branches-abc-fixture) + +ROOTTEST_GENERATE_REFLEX_DICTIONARY(abc_rflx abc.h + SELECTION selection.xml + LIBNAME libabc_rflx + NO_ROOTMAP + FIXTURES_SETUP root-tree-branches-libabc_rflx-fixture) + +set(_opts_cint -e "(void)gROOT->ProcessLine(\".L abc.h+\")") +set(_opts_rflx -e "(void)gSystem->Load(\"libabc_rflx\")") + +ROOTTEST_ADD_TEST(abc-cint-write + MACRO abcwrite.C + MACROARG "\"cint\"" + ROOTEXE_OPTS ${_opts_cint} + FIXTURES_REQUIRED root-tree-branches-abc-fixture + FIXTURES_SETUP root-tree-branches-abc-cint-write-fixture) + +ROOTTEST_ADD_TEST(abc-reflex-write + MACRO abcwrite.C + MACROARG "\"reflex\"" + ROOTEXE_OPTS ${_opts_rflx} + FIXTURES_REQUIRED root-tree-branches-libabc_rflx-fixture + FIXTURES_SETUP root-tree-branches-abc-reflex-write-fixture) + +ROOTTEST_ADD_TEST(abc-cint-cint-read + MACRO abcread.C + MACROARG "\"cint\",\"cint\"" + ROOTEXE_OPTS ${_opts_cint} + OUTREF abc.ref + FIXTURES_REQUIRED root-tree-branches-abc-cint-write-fixture + root-tree-branches-abc-fixture) + +ROOTTEST_ADD_TEST(abc-cint-reflex-read + MACRO abcread.C + MACROARG "\"cint\",\"reflex\"" + ROOTEXE_OPTS ${_opts_rflx} + OUTREF abc.ref + FIXTURES_REQUIRED root-tree-branches-abc-cint-write-fixture + root-tree-branches-libabc_rflx-fixture) + +ROOTTEST_ADD_TEST(abc-reflex-cint-read + MACRO abcread.C + MACROARG "\"reflex\",\"cint\"" + ROOTEXE_OPTS ${_opts_cint} + OUTREF abc.ref + FIXTURES_REQUIRED root-tree-branches-abc-reflex-write-fixture + root-tree-branches-abc-fixture) + +ROOTTEST_ADD_TEST(abc-reflex-reflex-read + MACRO abcread.C + MACROARG "\"reflex\",\"reflex\"" + ROOTEXE_OPTS ${_opts_rflx} + OUTREF abc.ref + FIXTURES_REQUIRED root-tree-branches-abc-reflex-write-fixture + root-tree-branches-libabc_rflx-fixture) + +ROOTTEST_ADD_TEST(MakeClass + MACRO assertMakeClass.C + ERRREF assertMakeClass.ref) + +ROOTTEST_ADD_TEST(bref + MACRO execbref.C + OUTREF execbref.ref) + +ROOTTEST_ADD_TEST(DupNames + MACRO execDupNames.cxx+ + OUTREF execDupNames.ref) + +ROOTTEST_ADD_TEST(EmptyBase + MACRO execEmptyBase.cxx+ + OUTREF execEmptyBase.ref) + +ROOTTEST_ADD_TEST(GetBranch + MACRO execGetBranch.cxx+ + OUTREF execGetBranch.ref) + +ROOTTEST_ADD_TEST(LeafFullName + MACRO execLeafFullName.cxx+ + OUTREF execLeafFullName.ref) + +ROOTTEST_ADD_TEST(WriteRead + MACRO execWriteRead.C + OUTREF execWriteRead.ref) + +ROOTTEST_ADD_TEST(simple + MACRO runsimple.C+ + OUTREF simple.ref) + +ROOTTEST_ADD_TEST(i_simple + MACRO runsimple.C + OUTREF i_simple.ref) + +ROOTTEST_ADD_TEST(noname + MACRO runnoname.C + OUTREF noname.ref) + +# on windows test fails while after reading of treeobj.root file branch.root left open +if(NOT MSVC OR win_broken_tests) + ROOTTEST_ADD_TEST(separate + MACRO runseparate.C + OUTREF separate.ref) +endif() + +ROOTTEST_ADD_TEST(updates + MACRO runupdates.C + OUTREF updates.ref) diff --git a/roottest/root/tree/branches/Makefile b/roottest/root/tree/branches/Makefile deleted file mode 100644 index 3a982fec07f8e..0000000000000 --- a/roottest/root/tree/branches/Makefile +++ /dev/null @@ -1,140 +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) branch.root treeobj.root abc*.root abc_rflx.cpp copy.root temp.root blah.root - -# 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 += noname simple i_simple separate abc updates - -# 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 -include $(ROOTTEST_HOME)/scripts/Reflex.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) - - - -noname: noname.log - $(TestDiff) - -simple: simple.clog - $(TestDiff) - -i_simple: simple.log - $(TestDiff) - -separate: separate.log - $(TestDiff) - -abc_rflx.cpp: abc.h - $(CMDECHO) genreflex abc.h > abc_reflex_cpp.log 2>&1 - -libabc_rflx_C.$(DllSuf): abc_rflx.cpp - - -ifneq ($(ClingWorkAroundMissingDynamicScope),) -abc_cint.root: CALLROOTEXE += -e 'gROOT->ProcessLine(".L abc.h+");' -endif - -abc_cint.root: abc_h.$(DllSuf) - $(CMDECHO) $(CALLROOTEXE) -b -l -q abcwrite.C\(\"cint\"\) > abc_cint.log 2>&1 - -abc_reflex.root: libabc_rflx_C.$(DllSuf) - $(CMDECHO) $(CALLROOTEXE) -b -l -q abcwrite.C\(\"reflex\"\) > abc_reflex.log 2>&1 - -ifneq ($(ClingWorkAroundMissingDynamicScope),) -abc.cintcint.log: CALLROOTEXE += -e 'gROOT->ProcessLine(".L abc.h+");' -endif - -abc.cintcint.log: abc_cint.root abc_h.$(DllSuf) - $(CMDECHO) $(CALLROOTEXE) -b -l -q abcread.C\(\"cint\",\"cint\"\) 2>&1 | grep -v Processing > abc.cintcint.log - -abc.cintreflex.log: abc_cint.root libabc_rflx_C.$(DllSuf) - $(CMDECHO) $(CALLROOTEXE) -b -l -q abcread.C\(\"cint\",\"reflex\"\) 2>&1 | grep -v Processing > abc.cintreflex.log - -abc.reflexcint.log: abc_reflex.root abc_h.$(DllSuf) - $(CMDECHO) $(CALLROOTEXE) -b -l -q abcread.C\(\"reflex\",\"cint\"\) 2>&1 | grep -v Processing > abc.reflexcint.log - -abc.reflexreflex.log: abc_reflex.root libabc_rflx_C.$(DllSuf) - $(CMDECHO) $(CALLROOTEXE) -b -l -q abcread.C\(\"reflex\",\"reflex\"\) 2>&1 | grep -v Processing > abc.reflexreflex.log - - -abc.cintcint.success: abc.cintcint.log - $(CMDECHO) diff -b -u abc.ref abc.cintcint.log && touch abc.cintcint.success - -abc.reflexcint.success: abc.reflexcint.log - $(CMDECHO) diff -b -u abc.ref abc.reflexcint.log && touch abc.reflexcint.success - -abc.cintreflex.success: abc.cintreflex.log - $(CMDECHO) diff -b -u abc.ref abc.cintreflex.log && touch abc.cintreflex.success - -abc.reflexreflex.success: abc.reflexreflex.log - $(CMDECHO) diff -b -u abc.ref abc.reflexreflex.log && touch abc.reflexreflex.success - -ifeq ($(findstring gccxml,$(notdir $(HAVEGCCXML))),gccxml) -abc: abc.cintcint.success abc.cintreflex.success abc.reflexcint.success abc.reflexreflex.success -else -abc: abc.cintcint.success -endif - -updates: updates.log - $(TestDiff) - -ifneq ($(ClingWorkAroundMissingAutoLoading),) -updates.log: CALLROOTEXE += -e 'gSystem->Load("libTreePlayer");' -endif - diff --git a/roottest/root/tree/branches/abc.h b/roottest/root/tree/branches/abc.h index 841100fc3db63..901cfcaece49c 100644 --- a/roottest/root/tree/branches/abc.h +++ b/roottest/root/tree/branches/abc.h @@ -1,15 +1,15 @@ -class ABC { +class BaseABC { public: - ABC(int i = -1): abc(i) {} - virtual ~ABC() {} + BaseABC(int i = -1): abc(i) {} + virtual ~BaseABC() {} virtual int pv() = 0; int abc; }; -class Derived: public ABC { +class Derived: public BaseABC { public: ~Derived() override {} - Derived(int i = -2): ABC(i+1), derived(i) {} + Derived(int i = -2): BaseABC(i+1), derived(i) {} int pv() override { return abc + derived; } int derived; @@ -17,11 +17,11 @@ class Derived: public ABC { class Holder { public: - Holder(): fABC(0) {} + Holder(): fABC(nullptr) {} ~Holder() { delete fABC; } void Set(int i) { delete fABC; fABC = new Derived(i); } - ABC* fABC; + BaseABC* fABC; }; diff --git a/roottest/root/tree/branches/abc.ref b/roottest/root/tree/branches/abc.ref index 2a1a3d8189b20..1f2710bc8913a 100644 --- a/roottest/root/tree/branches/abc.ref +++ b/roottest/root/tree/branches/abc.ref @@ -1,4 +1,5 @@ +Processing abcread.C... 20: read d.abc==20, d.derived==19 40: read d.abc==40, d.derived==39 60: read d.abc==60, d.derived==59 diff --git a/roottest/root/tree/branches/abcread.C b/roottest/root/tree/branches/abcread.C index e60378f3fbdac..e6c86920b3328 100644 --- a/roottest/root/tree/branches/abcread.C +++ b/roottest/root/tree/branches/abcread.C @@ -1,8 +1,5 @@ -#include "abcsetup.h" - -void abcread(const char* mode, const char* what) { - abcsetup(mode); - +void abcread(const char* mode, const char* what) +{ TFile f(TString::Format("abc_%s.root", mode)); TTree* t = 0; f.GetObject("tree", t); @@ -14,5 +11,5 @@ void abcread(const char* mode, const char* what) { Derived * d = (Derived*) h->fABC; std::cout << e << ": read d.abc==" << d->abc << ", d.derived==" << d->derived << std::endl; - } + } } diff --git a/roottest/root/tree/branches/abcsetup.h b/roottest/root/tree/branches/abcsetup.h deleted file mode 100644 index 150c0e603be81..0000000000000 --- a/roottest/root/tree/branches/abcsetup.h +++ /dev/null @@ -1,17 +0,0 @@ -void abcsetup(const char* mode) { - if (strchr(mode, 'c')) -#ifndef ClingWorkAroundMissingDynamicScope - gROOT->ProcessLine(".L abc.h+"); -#else - ; -#endif - else { - gSystem->Load("libCintex"); -#ifdef ClingWorkAroundMissingDynamicScope - gROOT->ProcessLine("ROOT::Cintex::Cintex::Enable();"); -#else - ROOT::Cintex::Cintex::Enable(); -#endif - gROOT->ProcessLine(".L libabc_rflx.C+"); - } -} diff --git a/roottest/root/tree/branches/abcwrite.C b/roottest/root/tree/branches/abcwrite.C index c645d9333fa3b..b5ed5fe5bf276 100644 --- a/roottest/root/tree/branches/abcwrite.C +++ b/roottest/root/tree/branches/abcwrite.C @@ -1,7 +1,5 @@ -#include "abcsetup.h" - -void abcwrite(const char* mode) { - abcsetup(mode); +void abcwrite(const char* mode) +{ Holder h; TFile f(TString::Format("abc_%s.root", mode), "recreate"); @@ -9,9 +7,7 @@ void abcwrite(const char* mode) { tree->Branch("h", &h); for (int e = 0; e < 100; ++e) { h.Set(e); -// gDebug = 3; - tree->Fill(); - gDebug = 0; + tree->Fill(); } tree->Write(); delete tree; diff --git a/roottest/root/tree/branches/execGetBranch.ref32 b/roottest/root/tree/branches/execGetBranch.ref32 deleted file mode 100644 index dd7d53a4ce63e..0000000000000 --- a/roottest/root/tree/branches/execGetBranch.ref32 +++ /dev/null @@ -1,30 +0,0 @@ - -Processing execGetBranch.cxx+... -Leaf name: i full name: i branch name: i branch full name: i -Leaf name: x full name: i.x branch name: x branch full name: i.x -Leaf name: x full name: x.x branch name: x branch full name: x -Leaf name: m. full name: m. branch name: m. branch full name: m. -Leaf name: m.x full name: m.x branch name: m.x branch full name: m.x -Leaf name: f full name: p.f branch name: p branch full name: p -Leaf name: x full name: p.x branch name: p branch full name: p -Leaf name: f full name: q.f branch name: q. branch full name: q. -Leaf name: x full name: q.x branch name: q. branch full name: q. -Error in : unknown branch -> x.x -Testing on TTree -Testing on TChain -Error in : unknown branch -> x.x -Error in : unknown branch -> x.x -Error in : unknown branch -> x.x -Error in : unknown branch -> x.x -Error in : unknown branch -> x.x -Error in : unknown branch -> x.x -Error in : unknown branch -> x.x -Error in : unknown branch -> x.x -Error in : unknown branch -> x.x -Error in : unknown branch -> x.x -Error in : unknown branch -> x.x -TTreeReader::Next: -TTreeReader::Next: -Error in : unknown branch -> x.x -Error in : unknown branch -> x.x -(int) 0 diff --git a/roottest/root/tree/branches/libabc_rflx.C b/roottest/root/tree/branches/libabc_rflx.C deleted file mode 100644 index 3b221cfdac706..0000000000000 --- a/roottest/root/tree/branches/libabc_rflx.C +++ /dev/null @@ -1 +0,0 @@ -#include "abc_rflx.cpp" diff --git a/roottest/root/tree/branches/selection.xml b/roottest/root/tree/branches/selection.xml new file mode 100644 index 0000000000000..6ac2ad2efb4ec --- /dev/null +++ b/roottest/root/tree/branches/selection.xml @@ -0,0 +1,5 @@ + + + + + diff --git a/roottest/root/tree/chain/.rootrc b/roottest/root/tree/chain/.rootrc deleted file mode 100644 index 6ebe75fd4ec5a..0000000000000 --- a/roottest/root/tree/chain/.rootrc +++ /dev/null @@ -1 +0,0 @@ -Rint.History: .root_hist diff --git a/roottest/root/tree/chain/CMakeLists.txt b/roottest/root/tree/chain/CMakeLists.txt index 182629f9610bb..46a2f95fd2d5c 100644 --- a/roottest/root/tree/chain/CMakeLists.txt +++ b/roottest/root/tree/chain/CMakeLists.txt @@ -1,8 +1,40 @@ -#------------------------------------------------------------------------------- -# -# 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(ChainElementStatus + MACRO execChainElementStatus.C + OUTREF execChainElementStatus.ref + OUTCNVCMD sed -e "s?: file [A-Za-z/\].*[/\]?: file ?" + COPY_TO_BUILDDIR st4.root st-empty.root st2.root st-notree.root st8.root) + +ROOTTEST_ADD_TEST(Cleanup + MACRO execCleanup.C + OUTREF execCleanup.ref) + +ROOTTEST_ADD_TEST(Empty + MACRO execEmpty.C + OUTREF execEmpty.ref + COPY_TO_BUILDDIR n_empty.root n_full.root) + +ROOTTEST_ADD_TEST(filenameformats + MACRO execfilenameformats.C + OUTREF execfilenameformats.ref) + +ROOTTEST_ADD_TEST(missingIndex + MACRO execmissingIndex.C + OUTREF execmissingIndex.ref) + +ROOTTEST_ADD_TEST(Notify + MACRO execNotify.C + OUTREF execNotify.ref) + +ROOTTEST_ADD_TEST(resetbranch + MACRO execresetbranch.C + OUTREF execresetbranch.ref) + +ROOTTEST_ADD_TEST(TChainCleanup + MACRO execTChainCleanup.cxx+ + OUTREF execTChainCleanup.ref) + +# to avoid copying of ROOT files - just run from source directory +ROOTTEST_ADD_TEST(subdir + MACRO runsubdir.C + WORKING_DIR ${CMAKE_CURRENT_SOURCE_DIR} + OUTREF subdir.ref) diff --git a/roottest/root/tree/chain/Makefile b/roottest/root/tree/chain/Makefile deleted file mode 100644 index db006e4e47f1c..0000000000000 --- a/roottest/root/tree/chain/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 *index*.root forchain.root tmp2.root ff_n*.root - -# 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 += subdir - -# 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) - -execCleanup.success: EXTRA_DIFFOPTS += -w -execmissingIndex.success: EXTRA_DIFFOPTS += -w - -ifneq ($(ClingWorkAroundMissingAutoLoading),) -execCleanup.log: CALLROOTEXE += -e 'gSystem->Load("libTreePlayer");' -execmissingIndex.log: CALLROOTEXE += -e 'gSystem->Load("libTreePlayer");' -execresetbranch.log: CALLROOTEXE += -e 'gSystem->Load("libTreePlayer");' -endif - -subdir: subdir.log - $(TestDiff) - -execChainElementStatus.log: execChainElementStatus.C - $(CMDECHO) $(CALLROOTEXE) -q -l -b execChainElementStatus.C 2>&1 | sed -e 's?: file [A-Za-z/\].*[/\]?: file ?' > execChainElementStatus.log 2>&1 || handleError.sh --cmd='Execution of execChainElementStatus.C > execChainElementStatus.log' --result=$? --log=execChainElementStatus.log ---test=execChainElementStatus - diff --git a/roottest/root/tree/chain/execCleanup.ref b/roottest/root/tree/chain/execCleanup.ref index b43d17ee34322..f2686c8c8e41f 100644 --- a/roottest/root/tree/chain/execCleanup.ref +++ b/roottest/root/tree/chain/execCleanup.ref @@ -1,3 +1,3 @@ Processing execCleanup.C... -(int)0 +(int) 0 diff --git a/roottest/root/tree/chain/execNotify.C b/roottest/root/tree/chain/execNotify.C index 451fab314f6ea..c8a9e23c5286e 100644 --- a/roottest/root/tree/chain/execNotify.C +++ b/roottest/root/tree/chain/execNotify.C @@ -1,5 +1,6 @@ #include "TObject.h" -#include + +#include class Notified : public TObject { unsigned int fValue = 0; @@ -34,5 +35,5 @@ void execNotifyImpl() { void execNotify() { execNotifyImpl(); execNotifyImpl(); - + } diff --git a/roottest/root/tree/cloning/.rootrc b/roottest/root/tree/cloning/.rootrc deleted file mode 100644 index 6ebe75fd4ec5a..0000000000000 --- a/roottest/root/tree/cloning/.rootrc +++ /dev/null @@ -1 +0,0 @@ -Rint.History: .root_hist diff --git a/roottest/root/tree/cloning/Makefile b/roottest/root/tree/cloning/Makefile deleted file mode 100644 index e52990def5c65..0000000000000 --- a/roottest/root/tree/cloning/Makefile +++ /dev/null @@ -1,84 +0,0 @@ -# This is a template for all makefile. - -#Set the list of files to be delete by clean: -CLEAN_TARGETS += *.log hsimple1.root hsimple2.root event1.root event2.root merge.root \ - pion_merged.root merged.root Event.new.split0.root \ - output_Coulomb_LER_study_small.root \ - CopyTree.root Event.h copiedEvent hsimple.out index*.root $(ALL_LIBRARIES) *.clog - - -#Set the list of target to make while testing -TEST_TARGETS += deepClass mergeWithDir treeCloneTest treeCloneTest2 index - -# 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 - - -Event.new.split0.root: copiedEvent$(ExeSuf) $(ROOTCORELIBS) - $(CMDECHO) $(MAKE) --no-print-directory -f $(EVENTDIR)/dt_Makefile EVENT=copiedEvent$(ExeSuf) Event.new.split0.root - -ifneq ($(ClingWorkAroundMissingAutoLoading),) -hsimple1.root: CALLROOTEXE += -e 'gSystem->Load("libTreePlayer");' -endif - -hsimple1.root: hsimple.C - $(CMDECHO) $(CALLROOTEXE) -q -l -b hsimple.C > hsimple.out - $(CMDECHO) mv hsimple.root hsimple1.root - $(CMDECHO) cp hsimple1.root hsimple2.root - -event1.root: Event.new.split0.root - $(CMDECHO) cp Event.new.split0.root event1.root - $(CMDECHO) cp event1.root event2.root - -ifneq ($(ClingWorkAroundBrokenUnnamedReturn),) -treeCloneTest.log: CALLROOTEXE += -e 'gSystem->Load("libTreePlayer");' -endif - -treeCloneTest.log: hsimple1.root event1.root runEvent.C run.C $(ROOTCORELIBS) - $(CMDECHO) ( $(CALLROOTEXE) -q -b -l run.C && $(CALLROOTEXE) -q -b -l runEvent.C ) > treeCloneTest.log 2>&1 - -treeCloneTest: treeCloneTest.log treeCloneTest.ref - $(CMDECHO) diff -ub treeCloneTest.ref treeCloneTest.log - -treeCloneTest2.log: runtreeCloneTest2.C $(ROOTCORELIBS) - $(CMDECHO) $(CALLROOTEXE) -b -q -l runtreeCloneTest2.C 2>&1 | grep -v Adding > treeCloneTest2.log - -treeCloneTest2: treeCloneTest2.log - $(TestDiff) - -testWithFailure: -ifeq ($(FAIL),) - $(WarnFailTest) -endif - -mergeWithDir: mergeWithDir.log - $(TestDiff) - -CopyTree.root: make_CopyTree.C ver_40200.root $(ROOTCORELIBS) - $(CMDECHO) $(CALLROOTEXE) -q -b -l make_CopyTree.C > make_CopyTree.log 2>&1 - -deepClass.log: CopyTree.root - -ifneq ($(ClingWorkAroundBrokenUnnamedReturn),) -deepClass: CINT_VERSION := brokenReturn -endif - -deepClass: deepClass.log - $(TestDiffCintSpecific) - -index: index.clog - $(TestDiff) - -ifneq ($(ClingWorkAroundMissingAutoLoading),) -treeCloneTest2.log: CALLROOTEXE += -e 'gSystem->Load("libTreePlayer");' -endif diff --git a/roottest/root/tree/cloning/root/.rootrc b/roottest/root/tree/cloning/root/.rootrc deleted file mode 100644 index 6ebe75fd4ec5a..0000000000000 --- a/roottest/root/tree/cloning/root/.rootrc +++ /dev/null @@ -1 +0,0 @@ -Rint.History: .root_hist diff --git a/roottest/root/tree/evolution/.rootrc b/roottest/root/tree/evolution/.rootrc deleted file mode 100644 index ef1466ce48926..0000000000000 --- a/roottest/root/tree/evolution/.rootrc +++ /dev/null @@ -1,2 +0,0 @@ -Rint.History: .root_hist -ACLiC.LinkLibs: 1 diff --git a/roottest/root/tree/evolution/CMakeLists.txt b/roottest/root/tree/evolution/CMakeLists.txt index 374514855ca45..d2f7508ceb3bd 100644 --- a/roottest/root/tree/evolution/CMakeLists.txt +++ b/roottest/root/tree/evolution/CMakeLists.txt @@ -1,7 +1,140 @@ -#------------------------------------------------------------------------------- -# -# 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) +# LABELS longtest + +ROOTTEST_ADD_TESTDIRS() + +ROOTTEST_COMPILE_MACRO(cloningOne.C + FIXTURES_SETUP root-tree-evolution-cloningOne-fixture) + +ROOTTEST_COMPILE_MACRO(cloningTwo.C + FIXTURES_SETUP root-tree-evolution-cloningTwo-fixture) + +if(ClingWorkAroundMissingDynamicScope) + set(_opts_cloningone -e "(void)gROOT->ProcessLine(\".L cloningOne.C+\")") + set(_opts_cloningtwo -e "(void)gROOT->ProcessLine(\".L cloningTwo.C+\")") +endif() + +ROOTTEST_ADD_TEST(cloningFile + MACRO runcloning.C + MACROARG 1 + ROOTEXE_OPTS ${_opts_cloningone} + FIXTURES_REQUIRED root-tree-evolution-cloningOne-fixture root-tree-evolution-cloningTwo-fixture + FIXTURES_SETUP root-tree-evolution-cloningFile-fixture) + +ROOTTEST_ADD_TEST(cloning + MACRO runcloning.C + ROOTEXE_OPTS ${_opts_cloningtwo} + FIXTURES_REQUIRED root-tree-evolution-cloningFile-fixture) + +ROOTTEST_COMPILE_MACRO(MyClassClones.cxx + FIXTURES_SETUP root-tree-evolution-MyClassClones-fixture) + +ROOTTEST_COMPILE_MACRO(MyClassVector.cxx + FIXTURES_SETUP root-tree-evolution-MyClassVector-fixture) + +ROOTTEST_COMPILE_MACRO(MyClassList.cxx + FIXTURES_SETUP root-tree-evolution-MyClassList-fixture) + +if(ClingWorkAroundMissingDynamicScope) + set(_opts_clones -e "(void)gROOT->ProcessLine(\".L MyClassClones.cxx+\")") + set(_opts_vector -e "(void)gROOT->ProcessLine(\".L MyClassVector.cxx+\")") + set(_opts_list -e "(void)gROOT->ProcessLine(\".L MyClassList.cxx+\")") +endif() + +ROOTTEST_ADD_TEST(WriteClones + MACRO WriteClones.C + ROOTEXE_OPTS ${_opts_clones} + FIXTURES_REQUIRED root-tree-evolution-MyClassClones-fixture + FIXTURES_SETUP root-tree-evolution-WriteClones-fixture) + +ROOTTEST_ADD_TEST(WriteVector + MACRO WriteVector.C + ROOTEXE_OPTS ${_opts_vector} + FIXTURES_REQUIRED root-tree-evolution-MyClassVector-fixture + FIXTURES_SETUP root-tree-evolution-WriteVector-fixture) + +ROOTTEST_ADD_TEST(WriteList + MACRO WriteList.C + ROOTEXE_OPTS ${_opts_list} + FIXTURES_REQUIRED root-tree-evolution-MyClassList-fixture + FIXTURES_SETUP root-tree-evolution-WriteList-fixture) + +ROOTTEST_ADD_TEST(ReadClones + MACRO ReadClones.C + FIXTURES_REQUIRED root-tree-evolution-MyClassClones-fixture + root-tree-evolution-WriteClones-fixture + root-tree-evolution-WriteVector-fixture + root-tree-evolution-WriteList-fixture + OUTREF ReadClones.ref) + +ROOTTEST_ADD_TEST(ReadVector + MACRO ReadVector.C + FIXTURES_REQUIRED root-tree-evolution-MyClassVector-fixture + root-tree-evolution-WriteClones-fixture + root-tree-evolution-WriteVector-fixture + root-tree-evolution-WriteList-fixture + OUTREF ReadVector.ref) + +ROOTTEST_ADD_TEST(ReadList + MACRO ReadList.C + FIXTURES_REQUIRED root-tree-evolution-MyClassList-fixture + root-tree-evolution-WriteClones-fixture + root-tree-evolution-WriteVector-fixture + root-tree-evolution-WriteList-fixture + OUTREF ReadList.ref) + +ROOTTEST_ADD_TEST(ReadNolib + MACRO ReadNolib.C + FIXTURES_REQUIRED root-tree-evolution-WriteClones-fixture + root-tree-evolution-WriteVector-fixture + root-tree-evolution-WriteList-fixture + OUTREF ReadNolib.ref) + +ROOTTEST_COMPILE_MACRO(SimpleOne.C + FIXTURES_SETUP root-tree-evolution-SimpleOne-fixture) + +ROOTTEST_COMPILE_MACRO(SimpleTwo.C + FIXTURES_SETUP root-tree-evolution-SimpleTwo-fixture) + +if(ClingWorkAroundMissingDynamicScope) + set(_opts_one -e "(void)gROOT->ProcessLine(\".L SimpleOne.C+\")") + set(_opts_two -e "(void)gROOT->ProcessLine(\".L SimpleTwo.C+\")") +endif() + +ROOTTEST_ADD_TEST(WriteOne + MACRO SimpleWrite.C + MACROARG 1 + ROOTEXE_OPTS ${_opts_one} + FIXTURES_REQUIRED root-tree-evolution-SimpleOne-fixture + FIXTURES_SETUP root-tree-evolution-WriteOne-fixture) + +ROOTTEST_ADD_TEST(WriteTwo + MACRO SimpleWrite.C + MACROARG 2 + ROOTEXE_OPTS ${_opts_two} + FIXTURES_REQUIRED root-tree-evolution-SimpleTwo-fixture + FIXTURES_SETUP root-tree-evolution-WriteTwo-fixture) + +ROOTTEST_ADD_TEST(SimpleRead + MACRO SimpleRead.C + OUTREF SimpleRead.ref + FIXTURES_REQUIRED root-tree-evolution-WriteOne-fixture + root-tree-evolution-WriteTwo-fixture) + +ROOTTEST_ADD_TEST(writeMissingCollection + MACRO writeMissingCollection.cxx+ + FIXTURES_SETUP root-tree-evolution-writeMissingCollection-fixture) + +ROOTTEST_ADD_TEST(MissingCollection + MACRO execMissingCollection.cxx+ + OUTREF execMissingCollection.ref + FIXTURES_REQUIRED root-tree-evolution-writeMissingCollection-fixture) + +ROOTTEST_ADD_TEST(missingArray1 + MACRO missingArray1.cc+ + FIXTURES_SETUP root-tree-evolution-missingArray1-fixture) + +ROOTTEST_ADD_TEST(missingArray2 + MACRO missingArray2.cc+ + OUTREF missingArray.ref + FIXTURES_REQUIRED root-tree-evolution-missingArray1-fixture) + diff --git a/roottest/root/tree/evolution/Makefile b/roottest/root/tree/evolution/Makefile deleted file mode 100644 index dcc72613f5e04..0000000000000 --- a/roottest/root/tree/evolution/Makefile +++ /dev/null @@ -1,178 +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 clonesfile.root cloning2.root cloning.root listfile.root \ - missingArray.root missingCollection.root SimpleOne.root SimpleTwo.root vectorfile.root - -# 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 += cloning mytest SimpleTest containerEvolution missingArray - -# 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) - -MyClassClones_cxx.$(DllSuf): MyClass.h MyClassClones.cxx - -MyClassVector_cxx.$(DllSuf): MyClass.h MyClassVector.cxx - -MyClassList_cxx.$(DllSuf) : MyClass.h MyClassVector.cxx - -ifneq ($(ClingWorkAroundMissingDynamicScope),) -clonesfile.root: CALLROOTEXE += -e 'gROOT->ProcessLine(".L MyClassClones.cxx+");' -endif - -clonesfile.root: $(ROOTCORELIBS) MyClassClones_cxx.$(DllSuf) WriteClones.C - $(CMDECHO) $(CALLROOTEXE) -q -b -l WriteClones.C > WriteClones.log 2>&1 || handleError.sh --result=$$? --log=WriteClones.log - -ifneq ($(ClingWorkAroundMissingDynamicScope),) -vectorfile.root: CALLROOTEXE += -e 'gROOT->ProcessLine(".L MyClassVector.cxx+");' -endif - -vectorfile.root: $(ROOTCORELIBS) MyClassVector_cxx.$(DllSuf) WriteVector.C - $(CMDECHO) $(CALLROOTEXE) -q -b -l WriteVector.C > WriteVector.log 2>&1 || handleError.sh --result=$$? --log=WriteVector.log - -ifneq ($(ClingWorkAroundMissingDynamicScope),) -listfile.root: CALLROOTEXE += -e 'gROOT->ProcessLine(".L MyClassList.cxx+");' -endif - -listfile.root: $(ROOTCORELIBS) MyClassList_cxx.$(DllSuf) WriteList.C - $(CMDECHO) $(CALLROOTEXE) -q -b -l WriteList.C > WriteList.log 2>&1 || handleError.sh --result=$$? --log=WriteList.log - -ReadClones.log: $(ROOTCORELIBS) MyClassClones_cxx.$(DllSuf) ReadClones.C clonesfile.root vectorfile.root listfile.root - $(CMDECHO) $(CALLROOTEXE) -q -b -l ReadClones.C > ReadClones.log 2>&1 || handleError.sh --result=$$? --log=ReadClones.log - -ReadVector.log: $(ROOTCORELIBS) MyClassVector_cxx.$(DllSuf) ReadVector.C clonesfile.root vectorfile.root listfile.root - $(CMDECHO) $(CALLROOTEXE) -q -b -l ReadVector.C > ReadVector.log 2>&1 || handleError.sh --result=$$? --log=ReadVector.log - -ReadList.log: $(ROOTCORELIBS) MyClassList_cxx.$(DllSuf) ReadList.C clonesfile.root vectorfile.root listfile.root - $(CMDECHO) $(CALLROOTEXE) -q -b -l ReadList.C > ReadList.log 2>&1 || handleError.sh --result=$$? --log=ReadList.log - -ReadNolib.log: $(ROOTCORELIBS) ReadNolib.C clonesfile.root vectorfile.root listfile.root - $(CMDECHO) $(CALLROOTEXE) -q -b -l ReadNolib.C > ReadNolib.raw.log 2>&1 ; result=$$? ; \ - cat ReadNolib.raw.log | grep -v 'Warning in : no dictionary for class' > ReadNolib.log ; \ - test $$result -eq 0 || handleError.sh --result=$$? --log=ReadNoLib.log - -containerEvolution.log: $(ROOTCORELIBS) MyClassClones_cxx.$(DllSuf) MyClassVector_cxx.$(DllSuf) MyClassList_cxx.$(DllSuf) - -containerEvolution: containerEvolution.log ReadClones ReadVector ReadList ReadNolib - $(TestDiff) - -.PHONY: ReadClones ReadVector ReadList ReadNolib -ReadClones: ReadClones.log - $(TestDiffW) -ReadVector: ReadVector.log - $(TestDiffW) -ReadList: ReadList.log - $(TestDiffW) -ReadNolib: ReadNolib.log - $(TestDiffW) - -SimpleOne_C.$(DllSuf): Simple.h -SimpleTwo_C.$(DllSuf): Simple.h - -ifneq ($(ClingWorkAroundMissingDynamicScope),) -SimpleOne.root: CALLROOTEXE += -e 'gROOT->ProcessLine(".L SimpleOne.C+");' - -SimpleTwo.root: CALLROOTEXE += -e 'gROOT->ProcessLine(".L SimpleTwo.C+");' - -endif - -SimpleOne.root: SimpleOne_C.$(DllSuf) SimpleWrite.C $(ROOTCORELIBS) - $(CMDECHO) $(CALLROOTEXE) -q -b -l 'SimpleWrite.C(1)' > SimpleWriteOne.log - -SimpleTwo.root: SimpleTwo_C.$(DllSuf) SimpleWrite.C $(ROOTCORELIBS) - $(CMDECHO) $(CALLROOTEXE) -q -b -l 'SimpleWrite.C(2)' > SimpleWriteTwo.log - -SimpleRead.log: SimpleOne.root SimpleTwo.root SimpleRead.C $(ROOTCORELIBS) - $(CMDECHO) $(CALLROOTEXE) -q -b -l SimpleRead.C > SimpleRead.log 2>&1 - -SimpleTest: SimpleRead.log - $(CMDECHO) diff -u -b -w SimpleRead.ref SimpleRead.log - -ifneq ($(ClingWorkAroundMissingDynamicScope),) -# cloning.root: CALLROOTEXE += -e 'gROOT->ProcessLine(".L cloningOne.C+");' - -cloning.log: CALLROOTEXE += -e 'gROOT->ProcessLine(".L cloningTwo.C+");' -endif - -cloning.root: cloningOne_C.$(DllSuf) cloningTwo_C.$(DllSuf) - $(CMDECHO) $(CALLROOTEXE) -q -b -l 'runcloning.C(1)' > cloning_root.log - -cloning.log: cloningTwo_C.$(DllSuf) cloning.root - -cloning: cloning.log -ifeq ($(FAIL),) - $(WarnFailTest) -else - $(TestDiff) -endif - -missingArray.root: missingArray1_cc.$(DllSuf) - $(CMDECHO) $(CALLROOTEXE) -q -b -l 'missingArray1.cc+' > missingArray.root_root.log - -missingArray.clog: missingArray.root missingArray2_cc.$(DllSuf) - $(CMDECHO) $(CALLROOTEXE) -q -b -l 'missingArray2.cc+' > missingArray.clog - -missingArray: missingArray.clog - $(TestDiffW) - -missingCollection.root: writeMissingCollection_cxx.$(DllSuf) - $(CMDECHO) $(CALLROOTEXE) -q -b -l writeMissingCollection.cxx+ > writeMissingCollection.clog 2>&1 || handleError.sh --result=$$? --log=writeMissingCollection.clog - -execMissingCollection.clog: missingCollection.root - -execMissingCollection.success: EXTRA_DIFFOPTS += -w diff --git a/roottest/root/tree/evolution/MyClassList.cxx b/roottest/root/tree/evolution/MyClassList.cxx old mode 100755 new mode 100644 diff --git a/roottest/root/tree/evolution/ReadList.C b/roottest/root/tree/evolution/ReadList.C old mode 100755 new mode 100644 diff --git a/roottest/root/tree/evolution/ReadNolib.C b/roottest/root/tree/evolution/ReadNolib.C old mode 100755 new mode 100644 diff --git a/roottest/root/tree/evolution/ReadNolib.ref b/roottest/root/tree/evolution/ReadNolib.ref index 9ebdfaf1ea193..c163410e6ed03 100644 --- a/roottest/root/tree/evolution/ReadNolib.ref +++ b/roottest/root/tree/evolution/ReadNolib.ref @@ -1,5 +1,8 @@ Processing ReadNolib.C... +Warning in : no dictionary for class TopLevel is available +Warning in : no dictionary for class Track is available +Warning in : no dictionary for class TopLevelCl is available ************************************************************* * Row * Instance * fTracks.fEnergy * ************************************************************* diff --git a/roottest/root/tree/evolution/ReadVector.C b/roottest/root/tree/evolution/ReadVector.C old mode 100755 new mode 100644 diff --git a/roottest/root/tree/evolution/SimpleRead.ref b/roottest/root/tree/evolution/SimpleRead.ref old mode 100755 new mode 100644 diff --git a/roottest/root/tree/evolution/WriteList.C b/roottest/root/tree/evolution/WriteList.C old mode 100755 new mode 100644 diff --git a/roottest/root/tree/evolution/WriteVector.C b/roottest/root/tree/evolution/WriteVector.C old mode 100755 new mode 100644 diff --git a/roottest/root/tree/evolution/containerEvolution.ref b/roottest/root/tree/evolution/containerEvolution.ref deleted file mode 100644 index 26a3d8c5b346b..0000000000000 --- a/roottest/root/tree/evolution/containerEvolution.ref +++ /dev/null @@ -1,2 +0,0 @@ - -Processing runcontainerEvolution.C... diff --git a/roottest/root/tree/evolution/runcontainerEvolution.C b/roottest/root/tree/evolution/runcontainerEvolution.C deleted file mode 100644 index b8565a89f01b2..0000000000000 --- a/roottest/root/tree/evolution/runcontainerEvolution.C +++ /dev/null @@ -1,3 +0,0 @@ -{ -// Fill out the code of the actual test -} diff --git a/roottest/root/tree/evolution/split/.rootrc b/roottest/root/tree/evolution/split/.rootrc deleted file mode 100644 index 6ebe75fd4ec5a..0000000000000 --- a/roottest/root/tree/evolution/split/.rootrc +++ /dev/null @@ -1 +0,0 @@ -Rint.History: .root_hist diff --git a/roottest/root/tree/evolution/split/CMakeLists.txt b/roottest/root/tree/evolution/split/CMakeLists.txt new file mode 100644 index 0000000000000..57676ce0f5aeb --- /dev/null +++ b/roottest/root/tree/evolution/split/CMakeLists.txt @@ -0,0 +1,28 @@ +# LABELS longtest + +ROOTTEST_ADD_TEST(CreateFileFullObjRule + MACRO execCreateFileFullObjRule.cxx+ + OUTREF execCreateFileFullObjRule.ref + FIXTURES_SETUP root-tree-evolution-split-CreateFileFullObjRule-fixture) + +ROOTTEST_ADD_TEST(ReadFileFullObjRule + MACRO execReadFileFullObjRule.cxx+ + OUTREF execReadFileFullObjRule.ref + FIXTURES_REQUIRED root-tree-evolution-split-CreateFileFullObjRule-fixture) + +ROOTTEST_ADD_TEST(makeclass + MACRO execmakeclass.C + OUTREF execmakeclass.ref) + +ROOTTEST_ADD_TEST(missingsplit_write + MACRO missingsplit_write.C+ + FIXTURES_SETUP root-tree-evolution-split-missingsplit_write-fixture) + +ROOTTEST_COMPILE_MACRO(missingsplit_read.C + FIXTURES_SETUP root-tree-evolution-split-missingsplit_read-fixture) + +ROOTTEST_ADD_TEST(missingsplit + MACRO runmissingsplit.C + OUTREF missingsplit.ref + FIXTURES_REQUIRED root-tree-evolution-split-missingsplit_write-fixture + root-tree-evolution-split-missingsplit_read-fixture) diff --git a/roottest/root/tree/evolution/split/Makefile b/roottest/root/tree/evolution/split/Makefile deleted file mode 100644 index d37b59344099e..0000000000000 --- a/roottest/root/tree/evolution/split/Makefile +++ /dev/null @@ -1,79 +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 missingsplit.root - -# 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 += missingsplit - -# 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) - -missingsplit.root: missingsplit_write_C.$(DllSuf) - $(CMDECHO) $(CALLROOTEXE) -b -q -l missingsplit_write.C+ > missingsplit_root.log 2>&1 - -missingsplit.log: missingsplit_read_C.$(DllSuf) missingsplit.root - -missingsplit: missingsplit.log missingsplit.ref - $(TestDiff) - -execReadFileFullObjRule.clog: execCreateFileFullObjRule.success - - - diff --git a/roottest/root/tree/evolution/split/execmakeclass.C b/roottest/root/tree/evolution/split/execmakeclass.C index da5d961beb9d6..d66df329082f9 100644 --- a/roottest/root/tree/evolution/split/execmakeclass.C +++ b/roottest/root/tree/evolution/split/execmakeclass.C @@ -1,6 +1,7 @@ #include "TTree.h" -TTree *create() { +TTree *create() +{ TTree *t = new TTree("t","t"); TNamed data("name","title"); t->Branch("data.",&data); @@ -10,7 +11,8 @@ TTree *create() { return t; } -void execmakeclass() { +void execmakeclass() +{ TTree *t = create(); t->SetMakeClass(1); Int_t bits = 0;