diff --git a/FWCore/Framework/BuildFile.xml b/FWCore/Framework/BuildFile.xml
index 4e1a56b09baa5..f41a112b5f5fc 100644
--- a/FWCore/Framework/BuildFile.xml
+++ b/FWCore/Framework/BuildFile.xml
@@ -1,4 +1,5 @@
+
diff --git a/FWCore/Framework/bin/cmsRun.cpp b/FWCore/Framework/bin/cmsRun.cpp
index 5a7c0a725b3b6..ffc005194bb41 100644
--- a/FWCore/Framework/bin/cmsRun.cpp
+++ b/FWCore/Framework/bin/cmsRun.cpp
@@ -3,6 +3,7 @@ This is a generic main that can be used with any plugin and a
PSet script. See notes in EventProcessor.cpp for details about it.
----------------------------------------------------------------------*/
+#include "FWCore/Framework/interface/CmsRunParser.h"
#include "FWCore/Framework/interface/EventProcessor.h"
#include "FWCore/Framework/interface/defaultCmsRunServices.h"
#include "FWCore/MessageLogger/interface/ExceptionMessages.h"
@@ -30,7 +31,6 @@ PSet script. See notes in EventProcessor.cpp for details about it.
#include "TError.h"
-#include "boost/program_options.hpp"
#include "oneapi/tbb/task_arena.h"
#include
@@ -41,24 +41,6 @@ PSet script. See notes in EventProcessor.cpp for details about it.
#include
#include
-//Command line parameters
-static char const* const kParameterSetOpt = "parameter-set";
-static char const* const kPythonOpt = "pythonOptions";
-static char const* const kParameterSetCommandOpt = "parameter-set,p";
-static char const* const kJobreportCommandOpt = "jobreport,j";
-static char const* const kJobreportOpt = "jobreport";
-static char const* const kEnableJobreportCommandOpt = "enablejobreport,e";
-static const char* const kEnableJobreportOpt = "enablejobreport";
-static char const* const kJobModeCommandOpt = "mode,m";
-static char const* const kJobModeOpt = "mode";
-static char const* const kNumberOfThreadsCommandOpt = "numThreads,n";
-static char const* const kNumberOfThreadsOpt = "numThreads";
-static char const* const kSizeOfStackForThreadCommandOpt = "sizeOfStackForThreadsInKB,s";
-static char const* const kSizeOfStackForThreadOpt = "sizeOfStackForThreadsInKB";
-static char const* const kHelpOpt = "help";
-static char const* const kHelpCommandOpt = "help,h";
-static char const* const kStrictOpt = "strict";
-
// -----------------------------------------------
namespace {
class EventProcessorWithSentry {
@@ -101,10 +83,9 @@ namespace {
private:
edm::EventProcessor* ep_;
};
-
} // namespace
-int main(int argc, char* argv[]) {
+int main(int argc, const char* argv[]) {
edm::TimingServiceBase::jobStarted();
int returnCode = 0;
@@ -116,7 +97,7 @@ int main(int argc, char* argv[]) {
edm::s_defaultSizeOfStackForThreadsInKB * 1024);
std::shared_ptr theMessageServicePresence;
std::unique_ptr jobReportStreamPtr;
- std::shared_ptr > jobRep;
+ std::shared_ptr> jobRep;
EventProcessorWithSentry proc;
try {
@@ -145,74 +126,39 @@ int main(int argc, char* argv[]) {
std::shared_ptr(edm::PresenceFactory::get()->makePresence("SingleThreadMSPresence").release());
context = "Processing command line arguments";
- std::string descString(argv[0]);
- descString += " [options] [--";
- descString += kParameterSetOpt;
- descString += "] config_file \nAllowed options";
- boost::program_options::options_description desc(descString);
-
- // clang-format off
- desc.add_options()(kHelpCommandOpt, "produce help message")(
- kParameterSetCommandOpt, boost::program_options::value(), "configuration file")(
- kJobreportCommandOpt,
- boost::program_options::value(),
- "file name to use for a job report file: default extension is .xml")(
- kEnableJobreportCommandOpt, "enable job report files (if any) specified in configuration file")(
- kJobModeCommandOpt,
- boost::program_options::value(),
- "Job Mode for MessageLogger defaults - default mode is grid")(
- kNumberOfThreadsCommandOpt,
- boost::program_options::value(),
- "Number of threads to use in job (0 is use all CPUs)")(
- kSizeOfStackForThreadCommandOpt,
- boost::program_options::value(),
- "Size of stack in KB to use for extra threads (0 is use system default size)")(kStrictOpt, "strict parsing");
- // clang-format on
-
- // anything at the end will be ignored, and sent to python
- boost::program_options::positional_options_description p;
- p.add(kParameterSetOpt, 1).add(kPythonOpt, -1);
-
- // This --fwk option is not used anymore, but I'm leaving it around as
- // it might be useful again in the future for code development
- // purposes. We originally used it when implementing the boost
- // state machine code.
- boost::program_options::options_description hidden("hidden options");
- hidden.add_options()("fwk", "For use only by Framework Developers")(
- kPythonOpt,
- boost::program_options::value >(),
- "options at the end to be passed to python");
-
- boost::program_options::options_description all_options("All Options");
- all_options.add(desc).add(hidden);
-
- boost::program_options::variables_map vm;
- try {
- store(boost::program_options::command_line_parser(argc, argv).options(all_options).positional(p).run(), vm);
- notify(vm);
- } catch (boost::program_options::error const& iException) {
- edm::LogAbsolute("CommandLineProcessing")
- << "cmsRun: Error while trying to process command line arguments:\n"
- << iException.what() << "\nFor usage and an options list, please do 'cmsRun --help'.";
- return edm::errors::CommandLineProcessing;
- }
-
- if (vm.count(kHelpOpt)) {
- std::cout << desc << std::endl;
- if (!vm.count(kParameterSetOpt))
+ edm::CmsRunParser parser(argv[0]);
+
+ const auto& parserOutput = parser.parse(argc, argv);
+ //return with exit code from parser
+ if (edm::CmsRunParser::hasExit(parserOutput))
+ return edm::CmsRunParser::getExit(parserOutput);
+ auto vm = edm::CmsRunParser::getVM(parserOutput);
+
+ std::string cmdString;
+ std::string fileName;
+ if (vm.count(edm::CmsRunParser::kCmdOpt)) {
+ cmdString = vm[edm::CmsRunParser::kCmdOpt].as();
+ if (vm.count(edm::CmsRunParser::kParameterSetOpt)) {
+ edm::LogAbsolute("CommandLineProcessing") << "cmsRun: Error while trying to process command line arguments:\n"
+ << "cannot use '-c [command line input]' with 'config_file'\n"
+ << "For usage and an options list, please do 'cmsRun --help'.";
edm::HaltMessageLogging();
- return 0;
- }
-
- if (!vm.count(kParameterSetOpt)) {
+ return edm::errors::CommandLineProcessing;
+ }
+ } else if (!vm.count(edm::CmsRunParser::kParameterSetOpt)) {
edm::LogAbsolute("ConfigFileNotFound") << "cmsRun: No configuration file given.\n"
<< "For usage and an options list, please do 'cmsRun --help'.";
edm::HaltMessageLogging();
return edm::errors::ConfigFileNotFound;
+ } else
+ fileName = vm[edm::CmsRunParser::kParameterSetOpt].as();
+ std::vector pythonOptValues;
+ if (vm.count(edm::CmsRunParser::kPythonOpt)) {
+ pythonOptValues = vm[edm::CmsRunParser::kPythonOpt].as>();
}
- std::string fileName(vm[kParameterSetOpt].as());
+ pythonOptValues.insert(pythonOptValues.begin(), fileName);
- if (vm.count(kStrictOpt)) {
+ if (vm.count(edm::CmsRunParser::kStrictOpt)) {
//edm::setStrictParsing(true);
edm::LogSystem("CommandLineProcessing") << "Strict configuration processing is now done from python";
}
@@ -221,9 +167,9 @@ int main(int argc, char* argv[]) {
// Decide whether to enable creation of job report xml file
// We do this first so any errors will be reported
std::string jobReportFile;
- if (vm.count(kJobreportOpt)) {
- jobReportFile = vm[kJobreportOpt].as();
- } else if (vm.count(kEnableJobreportOpt)) {
+ if (vm.count(edm::CmsRunParser::kJobreportOpt)) {
+ jobReportFile = vm[edm::CmsRunParser::kJobreportOpt].as();
+ } else if (vm.count(edm::CmsRunParser::kEnableJobreportOpt)) {
jobReportFile = "FrameworkJobReport.xml";
}
jobReportStreamPtr = jobReportFile.empty() ? nullptr : std::make_unique(jobReportFile.c_str());
@@ -234,15 +180,32 @@ int main(int argc, char* argv[]) {
jobRep.reset(new edm::serviceregistry::ServiceWrapper(std::move(jobRepPtr)));
edm::ServiceToken jobReportToken = edm::ServiceRegistry::createContaining(jobRep);
- context = "Processing the python configuration file named ";
- context += fileName;
+ if (!fileName.empty()) {
+ context = "Processing the python configuration file named ";
+ context += fileName;
+ } else {
+ context = "Processing the python configuration from command line ";
+ context += cmdString;
+ }
std::shared_ptr processDesc;
try {
- std::unique_ptr parameterSet = edm::readConfig(fileName, argc, argv);
- processDesc.reset(new edm::ProcessDesc(std::move(parameterSet)));
+ std::unique_ptr parameterSet;
+ if (!fileName.empty())
+ parameterSet = edm::readConfig(fileName, pythonOptValues);
+ else
+ edm::makeParameterSets(cmdString, parameterSet);
+ processDesc = std::make_shared(std::move(parameterSet));
} catch (edm::Exception const&) {
throw;
} catch (cms::Exception& iException) {
+ //check for "SystemExit: 0" on second line
+ const std::string& sysexit0("SystemExit: 0");
+ const auto& msg = iException.message();
+ size_t pos2 = msg.find('\n');
+ if (pos2 != std::string::npos and (msg.size() - (pos2 + 1)) > sysexit0.size() and
+ msg.compare(pos2 + 1, sysexit0.size(), sysexit0) == 0)
+ return 0;
+
edm::Exception e(edm::errors::ConfigFileReadError, "", iException);
throw e;
}
@@ -264,11 +227,11 @@ int main(int argc, char* argv[]) {
auto threadsInfo = threadOptions(*pset);
// check the command line options
- if (vm.count(kNumberOfThreadsOpt)) {
- threadsInfo.nThreads_ = vm[kNumberOfThreadsOpt].as();
+ if (vm.count(edm::CmsRunParser::kNumberOfThreadsOpt)) {
+ threadsInfo.nThreads_ = vm[edm::CmsRunParser::kNumberOfThreadsOpt].as();
}
- if (vm.count(kSizeOfStackForThreadOpt)) {
- threadsInfo.stackSize_ = vm[kSizeOfStackForThreadOpt].as();
+ if (vm.count(edm::CmsRunParser::kSizeOfStackForThreadOpt)) {
+ threadsInfo.stackSize_ = vm[edm::CmsRunParser::kSizeOfStackForThreadOpt].as();
}
// if needed, re-initialise TBB
@@ -290,8 +253,8 @@ int main(int argc, char* argv[]) {
context = "Setting MessageLogger defaults";
// Decide what mode of hardcoded MessageLogger defaults to use
- if (vm.count(kJobModeOpt)) {
- std::string jobMode = vm[kJobModeOpt].as();
+ if (vm.count(edm::CmsRunParser::kJobModeOpt)) {
+ std::string jobMode = vm[edm::CmsRunParser::kJobModeOpt].as();
edm::MessageDrop::instance()->jobMode = jobMode;
}
diff --git a/FWCore/Framework/interface/CmsRunParser.h b/FWCore/Framework/interface/CmsRunParser.h
new file mode 100644
index 0000000000000..26be819bb04c5
--- /dev/null
+++ b/FWCore/Framework/interface/CmsRunParser.h
@@ -0,0 +1,52 @@
+#ifndef FWCore_Framework_CmsRunParser_h
+#define FWCore_Framework_CmsRunParser_h
+
+#include "boost/program_options.hpp"
+
+#include
+
+namespace edm {
+ class CmsRunParser {
+ public:
+ using MapOrExit = std::variant;
+ CmsRunParser(const char* name);
+ MapOrExit parse(int argc, const char* argv[]) const;
+ //variant helpers
+ static bool hasVM(const MapOrExit& output) {
+ return std::holds_alternative(output);
+ }
+ static boost::program_options::variables_map getVM(const MapOrExit& output) {
+ return std::get(output);
+ }
+ static bool hasExit(const MapOrExit& output) { return std::holds_alternative(output); }
+ static int getExit(const MapOrExit& output) { return std::get(output); }
+
+ private:
+ boost::program_options::options_description desc_;
+ boost::program_options::options_description all_options_;
+ boost::program_options::positional_options_description pos_options_;
+
+ public:
+ //Command line parameters
+ static inline const char* const kParameterSetOpt = "parameter-set";
+ static inline const char* const kPythonOpt = "pythonOptions";
+ static inline const char* const kPythonOptDefault = "CMSRUN_PYTHONOPT_DEFAULT";
+ static inline const char* const kCmdCommandOpt = "command,c";
+ static inline const char* const kCmdOpt = "command";
+ static inline const char* const kJobreportCommandOpt = "jobreport,j";
+ static inline const char* const kJobreportOpt = "jobreport";
+ static inline const char* const kEnableJobreportCommandOpt = "enablejobreport,e";
+ static inline const char* const kEnableJobreportOpt = "enablejobreport";
+ static inline const char* const kJobModeCommandOpt = "mode,m";
+ static inline const char* const kJobModeOpt = "mode";
+ static inline const char* const kNumberOfThreadsCommandOpt = "numThreads,n";
+ static inline const char* const kNumberOfThreadsOpt = "numThreads";
+ static inline const char* const kSizeOfStackForThreadCommandOpt = "sizeOfStackForThreadsInKB,s";
+ static inline const char* const kSizeOfStackForThreadOpt = "sizeOfStackForThreadsInKB";
+ static inline const char* const kHelpOpt = "help";
+ static inline const char* const kHelpCommandOpt = "help,h";
+ static inline const char* const kStrictOpt = "strict";
+ };
+} // namespace edm
+
+#endif
diff --git a/FWCore/Framework/src/CmsRunParser.cc b/FWCore/Framework/src/CmsRunParser.cc
new file mode 100644
index 0000000000000..0f35733703595
--- /dev/null
+++ b/FWCore/Framework/src/CmsRunParser.cc
@@ -0,0 +1,123 @@
+#include "FWCore/Framework/interface/CmsRunParser.h"
+#include "FWCore/MessageLogger/interface/MessageLogger.h"
+#include "FWCore/Utilities/interface/EDMException.h"
+
+#include
+#include
+#include
+
+namespace {
+ //additional_parser is documented at https://www.boost.org/doc/libs/1_83_0/doc/html/program_options/howto.html#id-1.3.30.6.3
+ //extra_style_parser was added in https://www.boost.org/users/history/version_1_33_0.html
+ //it allows performing a fully custom processing on whatever arguments have not yet been processed
+ //the function is responsible for removing processed arguments from the input vector
+ //and assembling the return value, which is a vector of boost's option type
+ //some usage examples: https://stackoverflow.com/a/5481228, https://stackoverflow.com/a/37993517
+ //internally, when cmdline::run() is called, the function given to extra_style_parser is added to the beginning of list of parsers
+ //all parsers are called in order until args is empty (validity of non-empty output is checked after each parser)
+ std::vector final_opts_parser(std::vector& args) {
+ std::vector result;
+ std::string configName;
+ if (!args.empty() and !args[0].empty()) {
+ if (args[0][0] != '-') { // name is first positional arg -> doesn't start with '-'
+ configName = args[0];
+ args.erase(args.begin());
+ } else if (args[0] == "--" and args.size() > 1) { // name can start with '-' if separator comes first
+ configName = args[1];
+ args.erase(args.begin(), args.begin() + 2);
+ }
+ }
+ if (!configName.empty()) {
+ result.emplace_back(edm::CmsRunParser::kParameterSetOpt, std::vector(1, configName));
+ result.emplace_back();
+ auto& pythonOpts = result.back();
+ pythonOpts.string_key = edm::CmsRunParser::kPythonOpt;
+ pythonOpts.value.reserve(args.size());
+ pythonOpts.original_tokens.reserve(args.size());
+ for (const auto& arg : args) {
+ pythonOpts.value.push_back(arg);
+ pythonOpts.original_tokens.push_back(arg);
+ }
+ //default value to avoid "is missing" error
+ if (pythonOpts.value.empty()) {
+ pythonOpts.value.push_back(edm::CmsRunParser::kPythonOptDefault);
+ pythonOpts.original_tokens.push_back("");
+ }
+ args.clear();
+ }
+ return result;
+ }
+} // namespace
+
+namespace edm {
+ CmsRunParser::CmsRunParser(const char* name)
+ : desc_(std::string(name) + " [options] [--] config_file [python options]\nAllowed options"),
+ all_options_("All Options") {
+ // clang-format off
+ desc_.add_options()(kHelpCommandOpt, "produce help message")(
+ kJobreportCommandOpt,
+ boost::program_options::value(),
+ "file name to use for a job report file: default extension is .xml")(
+ kEnableJobreportCommandOpt, "enable job report files (if any) specified in configuration file")(
+ kJobModeCommandOpt,
+ boost::program_options::value(),
+ "Job Mode for MessageLogger defaults - default mode is grid")(
+ kNumberOfThreadsCommandOpt,
+ boost::program_options::value(),
+ "Number of threads to use in job (0 is use all CPUs)")(
+ kSizeOfStackForThreadCommandOpt,
+ boost::program_options::value(),
+ "Size of stack in KB to use for extra threads (0 is use system default size)")(kStrictOpt, "strict parsing")(
+ kCmdCommandOpt, boost::program_options::value(), "config passed in as string (cannot be used with config_file)");
+ // clang-format on
+
+ // anything at the end will be ignored, and sent to python
+ pos_options_.add(kParameterSetOpt, 1).add(kPythonOpt, -1);
+
+ // This --fwk option is not used anymore, but I'm leaving it around as
+ // it might be useful again in the future for code development
+ // purposes. We originally used it when implementing the boost
+ // state machine code.
+ boost::program_options::options_description hidden("hidden options");
+ hidden.add_options()("fwk", "For use only by Framework Developers")(
+ kParameterSetOpt, boost::program_options::value(), "configuration file")(
+ kPythonOpt,
+ boost::program_options::value>(),
+ "options at the end to be passed to python");
+
+ all_options_.add(desc_).add(hidden);
+ }
+ CmsRunParser::MapOrExit CmsRunParser::parse(int argc, const char* argv[]) const {
+ boost::program_options::variables_map vm;
+ try {
+ store(boost::program_options::command_line_parser(argc, argv)
+ .extra_style_parser(final_opts_parser)
+ .options(all_options_)
+ .positional(pos_options_)
+ .run(),
+ vm);
+ notify(vm);
+ } catch (boost::program_options::error const& iException) {
+ edm::LogAbsolute("CommandLineProcessing")
+ << "cmsRun: Error while trying to process command line arguments:\n"
+ << iException.what() << "\nFor usage and an options list, please do 'cmsRun --help'.";
+ return MapOrExit(edm::errors::CommandLineProcessing);
+ }
+
+ if (vm.count(kHelpOpt)) {
+ std::cout << desc_ << std::endl;
+ edm::HaltMessageLogging();
+ return MapOrExit(0);
+ }
+
+ //special handling of python options
+ if (vm.count(kPythonOpt)) {
+ const auto& pythonOptValues = vm[kPythonOpt].as>();
+ //omit default arg
+ if (pythonOptValues.size() == 1 and pythonOptValues[0] == kPythonOptDefault)
+ vm.erase(kPythonOpt);
+ }
+
+ return MapOrExit(vm);
+ }
+} // namespace edm
diff --git a/FWCore/Framework/test/BuildFile.xml b/FWCore/Framework/test/BuildFile.xml
index 0f5c8239fa1b8..59078d9979902 100644
--- a/FWCore/Framework/test/BuildFile.xml
+++ b/FWCore/Framework/test/BuildFile.xml
@@ -330,7 +330,7 @@
-test name="TestFWCoreFrameworkDeleteEarly" command="test_deleteEarly.sh"/>
+
@@ -362,19 +362,30 @@ test name="TestFWCoreFrameworkDeleteEarly" command="test_deleteEarly.sh"/>
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
-
+
-
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/FWCore/Framework/test/eventprocessor_t.cppunit.cc b/FWCore/Framework/test/eventprocessor_t.cppunit.cc
index 40ab6f826dbaa..2e2e0051181a9 100644
--- a/FWCore/Framework/test/eventprocessor_t.cppunit.cc
+++ b/FWCore/Framework/test/eventprocessor_t.cppunit.cc
@@ -402,7 +402,7 @@ void testeventprocessor::activityRegistryTest() {
" ivalue = cms.int32(-3))\n"
"process.p1 = cms.Path(process.m1)\n");
- std::shared_ptr parameterSet = ProcessDescImpl(configuration).parameterSet();
+ std::shared_ptr parameterSet = ProcessDescImpl(configuration, false).parameterSet();
auto processDesc = std::make_shared(parameterSet);
//We don't want any services, we just want an ActivityRegistry to be created
diff --git a/FWCore/Framework/test/help_cmsRun_tests.sh b/FWCore/Framework/test/help_cmsRun_tests.sh
new file mode 100644
index 0000000000000..b9112ef579200
--- /dev/null
+++ b/FWCore/Framework/test/help_cmsRun_tests.sh
@@ -0,0 +1,25 @@
+#!/bin/bash
+
+# Pass in name and status
+function die { echo $1: status $2 ; exit $2; }
+
+function doTest() {
+ TEST="$1"
+ CMD="$2"
+ PATTERN="$3"
+ PATTERN2="$4"
+ SHOULDFAIL="$5"
+ LOG="log_test$TEST.log"
+ if [ -z "$SHOULDFAIL" ]; then
+ $CMD >& $LOG || die "Test $TEST: failure running $CMD" 1
+ else
+ $CMD >& $LOG && die "Test $TEST: no error from $CMD" 1
+ fi
+ if [ -n "$PATTERN1" ]; then
+ (head -n 1 $LOG | grep -qF "$PATTERN") || die "Test $TEST: incorrect output from $CMD" $?
+ fi
+ if [ -n "$PATTERN2" ]; then
+ (grep -qF "$PATTERN2" $LOG) || die "Test $TEST: incorrect output from $CMD" $?
+ fi
+}
+
diff --git a/FWCore/Framework/test/run_XMLException.sh b/FWCore/Framework/test/run_XMLException.sh
index 5b10346e3c482..b871c7c25d02a 100755
--- a/FWCore/Framework/test/run_XMLException.sh
+++ b/FWCore/Framework/test/run_XMLException.sh
@@ -3,5 +3,5 @@
function die { echo Failure $1: status $2 ; exit $2 ; }
LOCAL_TEST_DIR="${CMSSW_BASE}/src/FWCore/Framework/test"
-cmsRun -j testXMLSafeException.xml -p ${LOCAL_TEST_DIR}/testXMLSafeException_cfg.py
+cmsRun -j testXMLSafeException.xml ${LOCAL_TEST_DIR}/testXMLSafeException_cfg.py
xmllint testXMLSafeException.xml || die "cmsRun testXMLSafeException_cfg.py produced invalid XML job report" $?
diff --git a/FWCore/Framework/test/run_cmsRun_argparse.sh b/FWCore/Framework/test/run_cmsRun_argparse.sh
new file mode 100755
index 0000000000000..c4155af3b8bc7
--- /dev/null
+++ b/FWCore/Framework/test/run_cmsRun_argparse.sh
@@ -0,0 +1,30 @@
+#!/bin/bash
+
+LOCAL_TEST_DIR="${CMSSW_BASE}/src/FWCore/Framework/test"
+source "${LOCAL_TEST_DIR}/help_cmsRun_tests.sh"
+
+# test cmsRun help
+doTest 1 "cmsRun --help ${LOCAL_TEST_DIR}/test_argparse.py" "cmsRun [options] [--] config_file [python options]"
+
+# test python help
+doTest 2 "cmsRun ${LOCAL_TEST_DIR}/test_argparse.py --help" "usage: test_argparse.py"
+
+# test nonexistent flag
+doTest 3 "cmsRun ${LOCAL_TEST_DIR}/test_argparse.py --nonexistent" "usage: test_argparse.py" "unrecognized arguments: --nonexistent" 1
+
+# test cmsRun args
+TEST4_OUT1="Namespace(maxEvents=1, jobreport='UNSET', enablejobreport='UNSET', mode='UNSET', numThreads='UNSET', sizeOfStackForThreadsInKB='UNSET', strict='UNSET', command='UNSET')"
+TEST4_OUT2="setting # threads 2"
+doTest 4 "cmsRun -n 2 ${LOCAL_TEST_DIR}/test_argparse.py" "$TEST4_OUT1" "$TEST4_OUT2"
+
+# test python args
+TEST=5
+TEST5_OUT1="Namespace(maxEvents=1, jobreport='UNSET', enablejobreport='UNSET', mode='UNSET', numThreads='2', sizeOfStackForThreadsInKB='UNSET', strict='UNSET', command='UNSET')"
+doTest $TEST "cmsRun ${LOCAL_TEST_DIR}/test_argparse.py -n 2" "$TEST5_OUT1"
+(grep -vqF "$TEST4_OUT2" log_test$TEST.log) || die "Test $TEST: incorrect output from $CMD" $?
+
+# test cmsRun args and python args together
+TEST=6
+TEST6_OUT1="Namespace(maxEvents=1, jobreport='UNSET', enablejobreport='UNSET', mode='UNSET', numThreads='3', sizeOfStackForThreadsInKB='UNSET', strict='UNSET', command='UNSET')"
+TEST6_OUT2="setting # threads 2"
+doTest $TEST "cmsRun -n 2 ${LOCAL_TEST_DIR}/test_argparse.py -n 3" "$TEST6_OUT1" "$TEST6_OUT2"
diff --git a/FWCore/Framework/test/run_cmsRun_argv.sh b/FWCore/Framework/test/run_cmsRun_argv.sh
new file mode 100755
index 0000000000000..82189e0884955
--- /dev/null
+++ b/FWCore/Framework/test/run_cmsRun_argv.sh
@@ -0,0 +1,16 @@
+#!/bin/bash
+
+LOCAL_TEST_DIR="${CMSSW_BASE}/src/FWCore/Framework/test"
+source "${LOCAL_TEST_DIR}/help_cmsRun_tests.sh"
+
+# test w/ no args
+doTest 1 "cmsRun ${LOCAL_TEST_DIR}/test_argv.py" "['${LOCAL_TEST_DIR}/test_argv.py']"
+
+# test w/ cmsRun args
+doTest 2 "cmsRun -n 2 ${LOCAL_TEST_DIR}/test_argv.py" "['${LOCAL_TEST_DIR}/test_argv.py']" "setting # threads 2"
+
+# test w/ python args
+doTest 3 "cmsRun ${LOCAL_TEST_DIR}/test_argv.py foo" "['${LOCAL_TEST_DIR}/test_argv.py', 'foo']"
+
+# test w/ cmsRun & python args
+doTest 4 "cmsRun -n 2 ${LOCAL_TEST_DIR}/test_argv.py foo" "['${LOCAL_TEST_DIR}/test_argv.py', 'foo']" "setting # threads 2"
diff --git a/FWCore/Framework/test/run_cmsRun_parsing.sh b/FWCore/Framework/test/run_cmsRun_parsing.sh
new file mode 100755
index 0000000000000..a3e4b87ca1241
--- /dev/null
+++ b/FWCore/Framework/test/run_cmsRun_parsing.sh
@@ -0,0 +1,28 @@
+#!/bin/bash -x
+
+LOCAL_TEST_DIR="${CMSSW_BASE}/src/FWCore/Framework/test"
+source "${LOCAL_TEST_DIR}/help_cmsRun_tests.sh"
+
+# test different config_file suffix (not .py)
+cp ${LOCAL_TEST_DIR}/test_argparse.py test_argparse.notpy
+doTest 1 "cmsRun -n 1 test_argparse.notpy" "" "TestArgParse"
+
+# test dash in config_file name
+cp -- ${LOCAL_TEST_DIR}/test_argparse.py -test_argparse.py
+doTest 2 "cmsRun -n 1 -- -test_argparse.py" "" "TestArgParse"
+
+# do these manually because quote nesting becomes a nightmare / perhaps actually impossible
+
+# test config as command line input
+TEST=3
+LOG="log_test$TEST.log"
+CONFIG_INPUT="import FWCore.ParameterSet.Config as cms; process = cms.Process('Test'); process.source=cms.Source('EmptySource'); process.maxEvents.input=10; print('Test3')"
+cmsRun -c "$CONFIG_INPUT" >& $LOG || die "Test $TEST: failure running cmsRun -c \"${CONFIG_INPUT}\""
+(grep -qF "Test3" $LOG) || die "Test $TEST: incorrect output from cmsRun -c \"${CONFIG_INPUT}\""
+
+# test command line input + config_file
+TEST=4
+LOG="log_test$TEST.log"
+CONFIG_INPUT="import FWCore.ParameterSet.Config as cms; process = cms.Process('Test'); process.source=cms.Source('EmptySource'); process.maxEvents.input=10"
+cmsRun -c "$CONFIG_INPUT" ${LOCAL_TEST_DIR}/test_argparse.py >& $LOG && die "Test $TEST: no error from cmsRun -c \"${CONFIG_INPUT}\" ${LOCAL_TEST_DIR}/test_argparse.py"
+(grep -qF "cannot use '-c [command line input]' with 'config_file'" $LOG) || die "Test $TEST: incorrect output from cmsRun -c \"${CONFIG_INPUT}\" ${LOCAL_TEST_DIR}/test_argparse.py"
diff --git a/FWCore/Framework/test/run_cmsRun_varparsing.sh b/FWCore/Framework/test/run_cmsRun_varparsing.sh
new file mode 100755
index 0000000000000..a8b732e4acaaf
--- /dev/null
+++ b/FWCore/Framework/test/run_cmsRun_varparsing.sh
@@ -0,0 +1,63 @@
+#!/bin/bash
+
+LOCAL_TEST_DIR="${CMSSW_BASE}/src/FWCore/Framework/test"
+source "${LOCAL_TEST_DIR}/help_cmsRun_tests.sh"
+
+# test cmsRun help
+doTest 1 "cmsRun --help ${LOCAL_TEST_DIR}/test_varparsing.py" "cmsRun [options] [--] config_file [python options]"
+
+# test python help
+doTest 2 "cmsRun ${LOCAL_TEST_DIR}/test_varparsing.py --help" "Singletons:
+ maxEvents: 1
+ - max events to process
+ threads : 1
+ - number of threads
+Lists:
+
+Options:
+ help : This screen
+ multipleAssign : Allows singletons to have multiple assignments
+ print : Prints out current values
+ XXX_clear : Clears list named 'XXX'
+"
+
+# test nonexistent flag
+TEST=3
+CMD="cmsRun ${LOCAL_TEST_DIR}/test_varparsing.py nonexistent=foo"
+$CMD >& log_test$TEST.log && die "Test $TEST: no error from $CMD" 1
+(head -n 1 log_test$TEST.log | grep -qF "Error: 'nonexistent' not registered.") || die "Test $TEST: incorrect output from $CMD" $?
+
+# test cmsRun args
+TEST4_OUT1="Singletons:
+ maxEvents: 1
+ - max events to process
+ threads : 1
+ - number of threads
+Lists:
+"
+TEST4_OUT2="setting # threads 2"
+doTest 4 "cmsRun -n 2 ${LOCAL_TEST_DIR}/test_varparsing.py" "$TEST4_OUT1" "$TEST4_OUT2"
+
+# test python args
+TEST=5
+TEST5_OUT1="Singletons:
+ maxEvents: 1
+ - max events to process
+ threads : 2
+ - number of threads
+Lists:
+"
+doTest $TEST "cmsRun ${LOCAL_TEST_DIR}/test_varparsing.py threads=2" "$TEST5_OUT1"
+(grep -vqF "$TEST4_OUT2" log_test$TEST.log) || die "Test $TEST: incorrect output from $CMD" $?
+
+# test cmsRun args and python args together
+TEST=6
+TEST6_OUT1="Singletons:
+ maxEvents: 1
+ - max events to process
+ threads : 3
+ - number of threads
+Lists:
+"
+TEST6_OUT2="setting # threads 2"
+doTest $TEST "cmsRun -n 2 ${LOCAL_TEST_DIR}/test_varparsing.py threads=3" "$TEST6_OUT1" "$TEST6_OUT2"
diff --git a/FWCore/Framework/test/run_testOptions.sh b/FWCore/Framework/test/run_testOptions.sh
index e90c81b5b4d39..e64720c030518 100755
--- a/FWCore/Framework/test/run_testOptions.sh
+++ b/FWCore/Framework/test/run_testOptions.sh
@@ -15,7 +15,7 @@ expectedStreams=(1 4 4 4 1)
expectedConcurrentLumis=(1 3 2 4 1)
expectedConcurrentIOVs=(1 2 2 4 1)
-cmsRun -p ${LOCAL_TEST_DIR}/${configFiles[$1]} >& ${configFiles[$1]}.log || die "cmsRun ${configFiles[$1]}" $?
+cmsRun ${LOCAL_TEST_DIR}/${configFiles[$1]} >& ${configFiles[$1]}.log || die "cmsRun ${configFiles[$1]}" $?
grep "Number of Streams = ${expectedStreams[$1]}" ${configFiles[$1]}.log || die "Failed number of streams test" $?
grep "Number of Concurrent Lumis = ${expectedConcurrentLumis[$1]}" ${configFiles[$1]}.log || die "Failed number of concurrent lumis test" $?
grep "Number of Concurrent IOVs = ${expectedConcurrentIOVs[$1]}" ${configFiles[$1]}.log || die "Failed number of concurrent IOVs test" $?
diff --git a/FWCore/Framework/test/run_wrongOptionsType.sh b/FWCore/Framework/test/run_wrongOptionsType.sh
index 962fcb93d3fa0..4c313183eba1a 100755
--- a/FWCore/Framework/test/run_wrongOptionsType.sh
+++ b/FWCore/Framework/test/run_wrongOptionsType.sh
@@ -5,5 +5,5 @@ VALUE=$2
function die { echo $1: status $2 ; echo === Log file === ; cat ${3:-/dev/null} ; echo === End log file === ; exit $2; }
-cmsRun ${SCRAM_TEST_PATH}/test_wrongOptionsType_cfg.py -- --name=${NAME} --value="$VALUE" > ${NAME}.log 2>&1 && die "cmsRun for ${NAME} succeeded, should have failed" 1 ${NAME}.log
+cmsRun ${SCRAM_TEST_PATH}/test_wrongOptionsType_cfg.py --name=${NAME} --value="$VALUE" > ${NAME}.log 2>&1 && die "cmsRun for ${NAME} succeeded, should have failed" 1 ${NAME}.log
grep -E "(The type in the configuration is incorrect)|(ValueError type of .* is expected to be .* but declared as)" ${NAME}.log > /dev/null || die "cmsRun for ${NAME} failed for other reason than incorrect configuration type" $? ${NAME}.log
diff --git a/FWCore/Framework/test/test_argparse.py b/FWCore/Framework/test/test_argparse.py
new file mode 100644
index 0000000000000..93e75faa73a7d
--- /dev/null
+++ b/FWCore/Framework/test/test_argparse.py
@@ -0,0 +1,23 @@
+import FWCore.ParameterSet.Config as cms
+from argparse import ArgumentParser
+
+parser = ArgumentParser(description='Test argparse')
+parser.add_argument("--maxEvents", help="max events to process", type=int, default=1)
+# same as cmsRun arguments; but ignored, just print values
+parser.add_argument("-j", "--jobreport", help="file name for job report file", type=str, default="UNSET")
+parser.add_argument("-e", "--enablejobreport", help="enable job report file(s)", default="UNSET", action="store_true")
+parser.add_argument("-m", "--mode", help="job mode for MessageLogger", type=str, default="UNSET")
+parser.add_argument("-n", "--numThreads", help="number of threads", type=str, default="UNSET")
+parser.add_argument("-s", "--sizeOfStackForThreadsInKB", help="size of thread stack in KB", type=str, default="UNSET")
+parser.add_argument("--strict", help="strict parsing", default="UNSET", action="store_true")
+parser.add_argument("-c", "--command", help="config passed in as string", type=str, default="UNSET")
+args = parser.parse_args()
+
+print(args)
+
+process = cms.Process("TEST")
+process.source = cms.Source("EmptySource")
+
+process.maxEvents.input = args.maxEvents
+
+print('TestArgParse')
diff --git a/FWCore/Framework/test/test_argv.py b/FWCore/Framework/test/test_argv.py
new file mode 100644
index 0000000000000..71d77869b4884
--- /dev/null
+++ b/FWCore/Framework/test/test_argv.py
@@ -0,0 +1,9 @@
+import FWCore.ParameterSet.Config as cms
+import sys
+
+print(sys.argv)
+
+process = cms.Process("TEST")
+process.source = cms.Source("EmptySource")
+
+process.maxEvents.input = 1
diff --git a/FWCore/Framework/test/test_bad_schedule_exception_message_cfg.py b/FWCore/Framework/test/test_bad_schedule_exception_message_cfg.py
index 3ba21b8d91f5d..bd5d0995b32b1 100644
--- a/FWCore/Framework/test/test_bad_schedule_exception_message_cfg.py
+++ b/FWCore/Framework/test/test_bad_schedule_exception_message_cfg.py
@@ -7,7 +7,7 @@
process.source = cms.Source("EmptySource")
-mod = int(sys.argv[2])
+mod = int(sys.argv[1])
process.load('FWCore.MessageService.MessageLogger_cfi')
process.MessageLogger.cerr.enable = False
diff --git a/FWCore/Framework/test/test_catch2_CmsRunParser.cc b/FWCore/Framework/test/test_catch2_CmsRunParser.cc
new file mode 100644
index 0000000000000..b4c50e31a820b
--- /dev/null
+++ b/FWCore/Framework/test/test_catch2_CmsRunParser.cc
@@ -0,0 +1,94 @@
+#include "catch.hpp"
+
+#include "FWCore/Framework/interface/CmsRunParser.h"
+#include "FWCore/Utilities/interface/EDMException.h"
+
+#include
+
+TEST_CASE("test cmsRun command line parsing", "[commandline]") {
+ edm::CmsRunParser parser("cmsRun");
+
+ SECTION("No arguments") {
+ constexpr int kSize = 1;
+ const char* args[kSize] = {"cmsRun"};
+ const auto& output = parser.parse(kSize, args);
+
+ REQUIRE(edm::CmsRunParser::hasVM(output));
+ auto vm = edm::CmsRunParser::getVM(output);
+
+ REQUIRE(not vm.count(edm::CmsRunParser::kHelpOpt));
+ REQUIRE(not vm.count(edm::CmsRunParser::kParameterSetOpt));
+ REQUIRE(not vm.count(edm::CmsRunParser::kStrictOpt));
+ REQUIRE(not vm.count(edm::CmsRunParser::kJobreportOpt));
+ REQUIRE(not vm.count(edm::CmsRunParser::kEnableJobreportOpt));
+ REQUIRE(not vm.count(edm::CmsRunParser::kNumberOfThreadsOpt));
+ REQUIRE(not vm.count(edm::CmsRunParser::kSizeOfStackForThreadOpt));
+ REQUIRE(not vm.count(edm::CmsRunParser::kJobModeOpt));
+ REQUIRE(not vm.count(edm::CmsRunParser::kPythonOpt));
+ REQUIRE(not vm.count(edm::CmsRunParser::kCmdOpt));
+ }
+
+ SECTION("help") {
+ constexpr int kSize = 2;
+ const char* args[kSize] = {"cmsRun", "-h"};
+ const auto& output = parser.parse(kSize, args);
+
+ REQUIRE(not edm::CmsRunParser::hasVM(output));
+ REQUIRE(edm::CmsRunParser::getExit(output) == 0);
+ }
+
+ SECTION("wrong") {
+ constexpr int kSize = 2;
+ const char* args[kSize] = {"cmsRun", "--wrong"};
+ const auto& output = parser.parse(kSize, args);
+
+ REQUIRE(not edm::CmsRunParser::hasVM(output));
+ REQUIRE(edm::CmsRunParser::getExit(output) == edm::errors::CommandLineProcessing);
+ }
+
+ SECTION("Config file only") {
+ constexpr int kSize = 2;
+ const std::string arg("config.py");
+ const char* args[kSize] = {"cmsRun", arg.c_str()};
+ const auto& output = parser.parse(kSize, args);
+
+ REQUIRE(edm::CmsRunParser::hasVM(output));
+ auto vm = edm::CmsRunParser::getVM(output);
+
+ REQUIRE(vm.count(edm::CmsRunParser::kParameterSetOpt));
+ REQUIRE(vm[edm::CmsRunParser::kParameterSetOpt].as() == arg);
+ REQUIRE(not vm.count(edm::CmsRunParser::kHelpOpt));
+ REQUIRE(not vm.count(edm::CmsRunParser::kStrictOpt));
+ REQUIRE(not vm.count(edm::CmsRunParser::kJobreportOpt));
+ REQUIRE(not vm.count(edm::CmsRunParser::kEnableJobreportOpt));
+ REQUIRE(not vm.count(edm::CmsRunParser::kNumberOfThreadsOpt));
+ REQUIRE(not vm.count(edm::CmsRunParser::kSizeOfStackForThreadOpt));
+ REQUIRE(not vm.count(edm::CmsRunParser::kJobModeOpt));
+ REQUIRE(not vm.count(edm::CmsRunParser::kPythonOpt));
+ REQUIRE(not vm.count(edm::CmsRunParser::kCmdOpt));
+ }
+
+ SECTION("Command line input only") {
+ constexpr int kSize = 3;
+ const std::string arg(
+ "import FWCore.ParameterSet.Config as cms; process = cms.Process('Test'); "
+ "process.source=cms.Source('EmptySource'); process.maxEvents.input=10; print('Test3')");
+ const char* args[kSize] = {"cmsRun", "-c", arg.c_str()};
+ const auto& output = parser.parse(kSize, args);
+
+ REQUIRE(edm::CmsRunParser::hasVM(output));
+ auto vm = edm::CmsRunParser::getVM(output);
+
+ REQUIRE(not vm.count(edm::CmsRunParser::kParameterSetOpt));
+ REQUIRE(not vm.count(edm::CmsRunParser::kHelpOpt));
+ REQUIRE(not vm.count(edm::CmsRunParser::kStrictOpt));
+ REQUIRE(not vm.count(edm::CmsRunParser::kJobreportOpt));
+ REQUIRE(not vm.count(edm::CmsRunParser::kEnableJobreportOpt));
+ REQUIRE(not vm.count(edm::CmsRunParser::kNumberOfThreadsOpt));
+ REQUIRE(not vm.count(edm::CmsRunParser::kSizeOfStackForThreadOpt));
+ REQUIRE(not vm.count(edm::CmsRunParser::kJobModeOpt));
+ REQUIRE(not vm.count(edm::CmsRunParser::kPythonOpt));
+ REQUIRE(vm.count(edm::CmsRunParser::kCmdOpt));
+ REQUIRE(vm[edm::CmsRunParser::kCmdOpt].as() == arg);
+ }
+}
diff --git a/FWCore/Framework/test/test_conditionaltasks_cfg.py b/FWCore/Framework/test/test_conditionaltasks_cfg.py
index 3c297b4592af2..92ab420aa2329 100644
--- a/FWCore/Framework/test/test_conditionaltasks_cfg.py
+++ b/FWCore/Framework/test/test_conditionaltasks_cfg.py
@@ -11,10 +11,7 @@
parser.add_argument("--testView", help="Get data via a view", action="store_true")
parser.add_argument("--aliasWithStar", help="when using testAlias use '*' as type", action="store_true")
-argv = sys.argv[:]
-if '--' in argv:
- argv.remove("--")
-args, unknown = parser.parse_known_args(argv)
+args = parser.parse_args()
process = cms.Process("Test")
diff --git a/FWCore/Framework/test/test_get_by_type_cfg.py b/FWCore/Framework/test/test_get_by_type_cfg.py
index 99ad74c48fb19..0edb9c0829638 100644
--- a/FWCore/Framework/test/test_get_by_type_cfg.py
+++ b/FWCore/Framework/test/test_get_by_type_cfg.py
@@ -5,12 +5,7 @@
parser = argparse.ArgumentParser(prog=sys.argv[0], description='Test getting many DataProducts just by type.')
parser.add_argument("--useEDAlias", action="store_true", help="add an EDAlias for one of the modules")
-
-argv = sys.argv[:]
-if '--' in argv:
- argv.remove("--")
-args, unknown = parser.parse_known_args(argv)
-
+args = parser.parse_args()
process = cms.Process("TEST")
diff --git a/FWCore/Framework/test/test_varparsing.py b/FWCore/Framework/test/test_varparsing.py
new file mode 100644
index 0000000000000..a4bc09547d357
--- /dev/null
+++ b/FWCore/Framework/test/test_varparsing.py
@@ -0,0 +1,14 @@
+import FWCore.ParameterSet.Config as cms
+from FWCore.ParameterSet.VarParsing import VarParsing
+
+options = VarParsing()
+options.register("maxEvents", 1, VarParsing.multiplicity.singleton, VarParsing.varType.int, "max events to process")
+options.register("threads", 1, VarParsing.multiplicity.singleton, VarParsing.varType.int, "number of threads")
+options.parseArguments()
+
+print(options)
+
+process = cms.Process("TEST")
+process.source = cms.Source("EmptySource")
+
+process.maxEvents.input = options.maxEvents
diff --git a/FWCore/Framework/test/test_wrongOptionsType_cfg.py b/FWCore/Framework/test/test_wrongOptionsType_cfg.py
index 4bd2c25a8c9c6..a6f72abbaee08 100644
--- a/FWCore/Framework/test/test_wrongOptionsType_cfg.py
+++ b/FWCore/Framework/test/test_wrongOptionsType_cfg.py
@@ -8,10 +8,7 @@
parser.add_argument("--name", help="Name of parameter", type=str)
parser.add_argument("--value", help="Value of the parameter", type=str)
-argv = sys.argv[:]
-if '--' in argv:
- argv.remove("--")
-args, unknown = parser.parse_known_args(argv)
+args = parser.parse_args()
process = cms.Process("TEST")
process.source = cms.Source("EmptySource")
diff --git a/FWCore/Framework/test/transition_test_cfg.py b/FWCore/Framework/test/transition_test_cfg.py
index 8a8f5bf29ff2c..e168e70bc931b 100644
--- a/FWCore/Framework/test/transition_test_cfg.py
+++ b/FWCore/Framework/test/transition_test_cfg.py
@@ -371,7 +371,7 @@ def chooseTrans(index):
print('****************************************')
return d[index][1]
-trans = chooseTrans(int(sys.argv[2]))
+trans = chooseTrans(int(sys.argv[1]))
process = cms.Process("TEST")
process.source = cms.Source("TestSource",
diff --git a/FWCore/Integration/test/BuildFile.xml b/FWCore/Integration/test/BuildFile.xml
index 0349aaac0eb23..123e0cb0cf339 100644
--- a/FWCore/Integration/test/BuildFile.xml
+++ b/FWCore/Integration/test/BuildFile.xml
@@ -77,23 +77,23 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
@@ -114,20 +114,20 @@
-
-
-
+
+
+
-
-
-
-
-
+
+
+
+
+
-
+
diff --git a/FWCore/Integration/test/ProcessAccelerator_t.cpp b/FWCore/Integration/test/ProcessAccelerator_t.cpp
index 78962773c0872..7dd31841cac9a 100644
--- a/FWCore/Integration/test/ProcessAccelerator_t.cpp
+++ b/FWCore/Integration/test/ProcessAccelerator_t.cpp
@@ -128,12 +128,14 @@ TEST_CASE("Configuration with SwitchProducer", s_tag) {
const std::string baseConfigTest2Disabled_test2 = makeSwitchConfig(false, test1, test2, "test2");
SECTION("Configuration hash is not changed") {
- auto pset_auto = edm::readConfig(baseConfig_auto);
- auto pset_test1 = edm::readConfig(baseConfig_test1);
- auto pset_test2 = edm::readConfig(baseConfig_test2);
- auto psetTest2Disabled_auto = edm::readConfig(baseConfigTest2Disabled_auto);
- auto psetTest2Disabled_test1 = edm::readConfig(baseConfigTest2Disabled_test1);
- auto psetTest2Disabled_test2 = edm::readConfig(baseConfigTest2Disabled_test2);
+ std::unique_ptr pset_auto, pset_test1, pset_test2;
+ std::unique_ptr psetTest2Disabled_auto, psetTest2Disabled_test1, psetTest2Disabled_test2;
+ edm::makeParameterSets(baseConfig_auto, pset_auto);
+ edm::makeParameterSets(baseConfig_test1, pset_test1);
+ edm::makeParameterSets(baseConfig_test2, pset_test2);
+ edm::makeParameterSets(baseConfigTest2Disabled_auto, psetTest2Disabled_auto);
+ edm::makeParameterSets(baseConfigTest2Disabled_test1, psetTest2Disabled_test1);
+ edm::makeParameterSets(baseConfigTest2Disabled_test2, psetTest2Disabled_test2);
pset_auto->registerIt();
pset_test1->registerIt();
pset_test2->registerIt();
@@ -224,14 +226,18 @@ TEST_CASE("Configuration with ModuleTypeResolver", s_tag) {
const std::string baseConfigOtherDisabled_other = makeResolverConfig(false, "other", "");
SECTION("Configuration hash is not changed") {
- auto pset_auto = edm::readConfig(baseConfig_auto);
- auto pset_cpu = edm::readConfig(baseConfig_cpu);
- auto pset_other = edm::readConfig(baseConfig_other);
- auto pset_cpuExplicit = edm::readConfig(baseConfig_cpuExplicit);
- auto pset_otherExplicit = edm::readConfig(baseConfig_otherExplicit);
- auto psetOtherDisabled_auto = edm::readConfig(baseConfigOtherDisabled_auto);
- auto psetOtherDisabled_cpu = edm::readConfig(baseConfigOtherDisabled_cpu);
- REQUIRE_THROWS_WITH(edm::readConfig(baseConfigOtherDisabled_other), Catch::Contains("UnavailableAccelerator"));
+ std::unique_ptr pset_auto, pset_cpu, pset_other, pset_cpuExplicit;
+ std::unique_ptr pset_otherExplicit, psetOtherDisabled_auto, psetOtherDisabled_cpu,
+ psetOtherDisabled_other;
+ edm::makeParameterSets(baseConfig_auto, pset_auto);
+ edm::makeParameterSets(baseConfig_cpu, pset_cpu);
+ edm::makeParameterSets(baseConfig_other, pset_other);
+ edm::makeParameterSets(baseConfig_cpuExplicit, pset_cpuExplicit);
+ edm::makeParameterSets(baseConfig_otherExplicit, pset_otherExplicit);
+ edm::makeParameterSets(baseConfigOtherDisabled_auto, psetOtherDisabled_auto);
+ edm::makeParameterSets(baseConfigOtherDisabled_cpu, psetOtherDisabled_cpu);
+ REQUIRE_THROWS_WITH(edm::makeParameterSets(baseConfigOtherDisabled_other, psetOtherDisabled_other),
+ Catch::Contains("UnavailableAccelerator"));
pset_auto->registerIt();
pset_cpu->registerIt();
pset_other->registerIt();
diff --git a/FWCore/Integration/test/SwitchProducer_t.cpp b/FWCore/Integration/test/SwitchProducer_t.cpp
index 464f0a242a2af..fb66b9ab73946 100644
--- a/FWCore/Integration/test/SwitchProducer_t.cpp
+++ b/FWCore/Integration/test/SwitchProducer_t.cpp
@@ -51,8 +51,9 @@ TEST_CASE("Configuration", s_tag) {
const std::string baseConfigTest2Disabled = makeConfig(false, test1, test2);
SECTION("Configuration hash is not changed") {
- auto pset = edm::readConfig(baseConfig);
- auto psetTest2Disabled = edm::readConfig(baseConfigTest2Disabled);
+ std::unique_ptr pset, psetTest2Disabled;
+ edm::makeParameterSets(baseConfig, pset);
+ edm::makeParameterSets(baseConfigTest2Disabled, psetTest2Disabled);
pset->registerIt();
psetTest2Disabled->registerIt();
REQUIRE(pset->id() == psetTest2Disabled->id());
@@ -107,8 +108,9 @@ TEST_CASE("Configuration with EDAlias", s_tag) {
const std::string baseConfigTest2Disabled = makeConfig(false, test1, test2, otherprod, othername);
SECTION("Configuration hash is not changed") {
- auto pset = edm::readConfig(baseConfig);
- auto psetTest2Disabled = edm::readConfig(baseConfigTest2Disabled);
+ std::unique_ptr pset, psetTest2Disabled;
+ edm::makeParameterSets(baseConfig, pset);
+ edm::makeParameterSets(baseConfigTest2Disabled, psetTest2Disabled);
pset->registerIt();
psetTest2Disabled->registerIt();
REQUIRE(pset->id() == psetTest2Disabled->id());
diff --git a/FWCore/Integration/test/ViewTest.sh b/FWCore/Integration/test/ViewTest.sh
index 4d68b9d6a8648..c9386c8108876 100755
--- a/FWCore/Integration/test/ViewTest.sh
+++ b/FWCore/Integration/test/ViewTest.sh
@@ -2,4 +2,4 @@
function die { echo $1: status $2 ; exit $2; }
-cmsRun --parameter-set ${SCRAM_TEST_PATH}/ViewTest_cfg.py || die 'Failed in ViewTest_cfg.py' $?
+cmsRun ${SCRAM_TEST_PATH}/ViewTest_cfg.py || die 'Failed in ViewTest_cfg.py' $?
diff --git a/FWCore/Integration/test/detsetvector_t.sh b/FWCore/Integration/test/detsetvector_t.sh
index 3b95f2c678e83..8ee2d38a198c0 100755
--- a/FWCore/Integration/test/detsetvector_t.sh
+++ b/FWCore/Integration/test/detsetvector_t.sh
@@ -2,5 +2,5 @@
function die { echo $1: status $2 ; exit $2; }
-cmsRun --parameter-set ${SCRAM_TEST_PATH}/detsetvector_t_cfg.py || die 'Failed in detsetvector_t_cfg.py' $?
+cmsRun ${SCRAM_TEST_PATH}/detsetvector_t_cfg.py || die 'Failed in detsetvector_t_cfg.py' $?
diff --git a/FWCore/Integration/test/eventHistoryTest.sh b/FWCore/Integration/test/eventHistoryTest.sh
index 5457ca779ce9c..bd709f2ef81f2 100755
--- a/FWCore/Integration/test/eventHistoryTest.sh
+++ b/FWCore/Integration/test/eventHistoryTest.sh
@@ -6,43 +6,43 @@ function die { echo $1: status $2 ; exit $2; }
LOCAL_TEST_DIR=${SCRAM_TEST_PATH}
# Write a file for the FIRST process
-cmsRun --parameter-set ${LOCAL_TEST_DIR}/EventHistory_1_cfg.py || die 'Failed in EventHistory_1' $?
+cmsRun ${LOCAL_TEST_DIR}/EventHistory_1_cfg.py || die 'Failed in EventHistory_1' $?
echo "*************************************************"
echo "**************** Finished pass 1 ****************"
echo "*************************************************"
# Read the first file, write the second.
-cmsRun --parameter-set ${LOCAL_TEST_DIR}/EventHistory_2_cfg.py || die 'Failed in EventHistory_2' $?
+cmsRun ${LOCAL_TEST_DIR}/EventHistory_2_cfg.py || die 'Failed in EventHistory_2' $?
echo "*************************************************"
echo "**************** Finished pass 2 ****************"
echo "*************************************************"
# Read the second file, write the third.
-cmsRun --parameter-set ${LOCAL_TEST_DIR}/EventHistory_3_cfg.py || die 'Failed in EventHistory_3' $?
+cmsRun ${LOCAL_TEST_DIR}/EventHistory_3_cfg.py || die 'Failed in EventHistory_3' $?
echo "*************************************************"
echo "**************** Finished pass 3 ****************"
echo "*************************************************"
# Read the third file, make sure the event data have the right history
-cmsRun --parameter-set ${LOCAL_TEST_DIR}/EventHistory_4_cfg.py || die 'Failed in EventHistory_4' $?
+cmsRun ${LOCAL_TEST_DIR}/EventHistory_4_cfg.py || die 'Failed in EventHistory_4' $?
echo "*************************************************"
echo "**************** Finished pass 4 ****************"
echo "*************************************************"
# Read the fourth file, make sure the event data have the right history
-cmsRun --parameter-set ${LOCAL_TEST_DIR}/EventHistory_5_cfg.py || die 'Failed in EventHistory_5' $?
+cmsRun ${LOCAL_TEST_DIR}/EventHistory_5_cfg.py || die 'Failed in EventHistory_5' $?
echo "*************************************************"
echo "**************** Finished pass 5 ****************"
echo "*************************************************"
# Read the fifth file, make sure the event data have the right history
-cmsRun --parameter-set ${LOCAL_TEST_DIR}/EventHistory_6_cfg.py || die 'Failed in EventHistory_6' $?
+cmsRun ${LOCAL_TEST_DIR}/EventHistory_6_cfg.py || die 'Failed in EventHistory_6' $?
echo "*************************************************"
echo "**************** Finished pass 6 ****************"
echo "*************************************************"
# Repeat all the above steps, but slightly modified so all steps run in one job with subprocess
-cmsRun --parameter-set ${LOCAL_TEST_DIR}/EventHistory_SubProcess_cfg.py || die 'Failed in EventHistory_SubProcess' $?
+cmsRun ${LOCAL_TEST_DIR}/EventHistory_SubProcess_cfg.py || die 'Failed in EventHistory_SubProcess' $?
echo "*************************************************"
echo "**************** Finished pass SubProcess *******"
echo "*************************************************"
diff --git a/FWCore/Integration/test/eventSetupTest.sh b/FWCore/Integration/test/eventSetupTest.sh
index 24abbd29b8a89..0b2a1303872ee 100755
--- a/FWCore/Integration/test/eventSetupTest.sh
+++ b/FWCore/Integration/test/eventSetupTest.sh
@@ -5,34 +5,34 @@ function diecat { echo "$1: status $2, log" ; cat $3; exit $2; }
LOCAL_TEST_DIR=${SCRAM_TEST_PATH}
-cmsRun --parameter-set ${LOCAL_TEST_DIR}/EventSetupTest_cfg.py || die 'Failed in EventSetupTest_cfg.py' $?
-cmsRun --parameter-set ${LOCAL_TEST_DIR}/EventSetupAppendLabelTest_cfg.py || die 'Failed in EventSetupAppendLabelTest_cfg.py' $?
-cmsRun --parameter-set ${LOCAL_TEST_DIR}/EventSetupTest2_cfg.py || die 'Failed in EventSetupTest2_cfg.py' $?
-cmsRun --parameter-set ${LOCAL_TEST_DIR}/EventSetupForceCacheClearTest_cfg.py || die 'Failed in EventSetupForceCacheClearTest_cfg.py' $?
+cmsRun ${LOCAL_TEST_DIR}/EventSetupTest_cfg.py || die 'Failed in EventSetupTest_cfg.py' $?
+cmsRun ${LOCAL_TEST_DIR}/EventSetupAppendLabelTest_cfg.py || die 'Failed in EventSetupAppendLabelTest_cfg.py' $?
+cmsRun ${LOCAL_TEST_DIR}/EventSetupTest2_cfg.py || die 'Failed in EventSetupTest2_cfg.py' $?
+cmsRun ${LOCAL_TEST_DIR}/EventSetupForceCacheClearTest_cfg.py || die 'Failed in EventSetupForceCacheClearTest_cfg.py' $?
echo testESProductHost
-cmsRun --parameter-set ${LOCAL_TEST_DIR}/ESProductHostTest_cfg.py || die 'Failed in ESProductHostTest_cfg.py' $?
+cmsRun ${LOCAL_TEST_DIR}/ESProductHostTest_cfg.py || die 'Failed in ESProductHostTest_cfg.py' $?
echo testConcurrentIOVs
-cmsRun --parameter-set ${LOCAL_TEST_DIR}/testConcurrentIOVs_cfg.py || die 'Failed in testConcurrentIOVs_cfg.py' $?
+cmsRun ${LOCAL_TEST_DIR}/testConcurrentIOVs_cfg.py || die 'Failed in testConcurrentIOVs_cfg.py' $?
echo testConcurrentIOVsLegacy
-cmsRun --parameter-set ${LOCAL_TEST_DIR}/testConcurrentIOVsLegacy_cfg.py || die 'Failed in testConcurrentIOVsLegacy_cfg.py' $?
+cmsRun ${LOCAL_TEST_DIR}/testConcurrentIOVsLegacy_cfg.py || die 'Failed in testConcurrentIOVsLegacy_cfg.py' $?
echo testAllowConcurrentIOVs_cfg
-cmsRun --parameter-set ${LOCAL_TEST_DIR}/testAllowConcurrentIOVs_cfg.py || die 'Failed in testAllowConcurrentIOVs_cfg.py' $?
+cmsRun ${LOCAL_TEST_DIR}/testAllowConcurrentIOVs_cfg.py || die 'Failed in testAllowConcurrentIOVs_cfg.py' $?
echo testConcurrentIOVsForce_cfg
-cmsRun --parameter-set ${LOCAL_TEST_DIR}/testConcurrentIOVsForce_cfg.py || die 'Failed in testConcurrentIOVsForce_cfg.py' $?
+cmsRun ${LOCAL_TEST_DIR}/testConcurrentIOVsForce_cfg.py || die 'Failed in testConcurrentIOVsForce_cfg.py' $?
echo testEventSetupRunLumi_cfg
-cmsRun --parameter-set ${LOCAL_TEST_DIR}/testEventSetupRunLumi_cfg.py || die 'Failed in testEventSetupRunLumi_cfg.py' $?
+cmsRun ${LOCAL_TEST_DIR}/testEventSetupRunLumi_cfg.py || die 'Failed in testEventSetupRunLumi_cfg.py' $?
echo testConcurrentIOVsESSource_cfg.py
-cmsRun --parameter-set ${LOCAL_TEST_DIR}/testConcurrentIOVsESSource_cfg.py || die 'Failed in testConcurrentIOVsESSource_cfg.py' $?
+cmsRun ${LOCAL_TEST_DIR}/testConcurrentIOVsESSource_cfg.py || die 'Failed in testConcurrentIOVsESSource_cfg.py' $?
echo testConcurrentIOVsESConcurrentSource_cfg.py
-cmsRun --parameter-set ${LOCAL_TEST_DIR}/testConcurrentIOVsESConcurrentSource_cfg.py || die 'Failed in testConcurrentIOVsESConcurrentSource_cfg.py' $?
+cmsRun ${LOCAL_TEST_DIR}/testConcurrentIOVsESConcurrentSource_cfg.py || die 'Failed in testConcurrentIOVsESConcurrentSource_cfg.py' $?
echo EventSetupTestCurrentProcess_cfg.py
cmsRun ${LOCAL_TEST_DIR}/EventSetupTestCurrentProcess_cfg.py || die 'Failed in EventSetupTestCurrentProcess_cfg.py' $?
@@ -42,10 +42,10 @@ cmsRun ${LOCAL_TEST_DIR}/EventSetupIncorrectConsumes_cfg.py &> testEventSetupInc
grep "A module declared it consumes an EventSetup product after its constructor" testEventSetupIncorrectConsumes.txt >/dev/null || diecat 'Failed EventSetupIncorrectConsumes_cfg.py, the configuration failed but in an unexpected way' $? testEventSetupIncorrectConsumes.txt
echo testConcurrentIOVsAndRuns_cfg.py
-cmsRun --parameter-set ${LOCAL_TEST_DIR}/testConcurrentIOVsAndRuns_cfg.py || die 'Failed in testConcurrentIOVsAndRuns_cfg.py' $?
+cmsRun ${LOCAL_TEST_DIR}/testConcurrentIOVsAndRuns_cfg.py || die 'Failed in testConcurrentIOVsAndRuns_cfg.py' $?
echo testConcurrentIOVsAndRunsRead_cfg.py
-cmsRun --parameter-set ${LOCAL_TEST_DIR}/testConcurrentIOVsAndRunsRead_cfg.py || die 'Failed in testConcurrentIOVsAndRunsRead_cfg.py' $?
+cmsRun ${LOCAL_TEST_DIR}/testConcurrentIOVsAndRunsRead_cfg.py || die 'Failed in testConcurrentIOVsAndRunsRead_cfg.py' $?
echo testESProducerUsingAcquire_cfg.py
cmsRun ${LOCAL_TEST_DIR}/testESProducerUsingAcquire_cfg.py || die 'Failed in testESProducerUsingAcquire_cfg.py' $?
diff --git a/FWCore/Integration/test/hierarchy_example.sh b/FWCore/Integration/test/hierarchy_example.sh
index 93e0f537235ff..fadd28edc80d7 100755
--- a/FWCore/Integration/test/hierarchy_example.sh
+++ b/FWCore/Integration/test/hierarchy_example.sh
@@ -2,5 +2,5 @@
function die { echo $1: status $2 ; exit $2; }
-cmsRun --parameter-set ${SCRAM_TEST_PATH}/hierarchy_example_cfg.py || die 'Failed in hierarchy_example_cfg.py' $?
+cmsRun ${SCRAM_TEST_PATH}/hierarchy_example_cfg.py || die 'Failed in hierarchy_example_cfg.py' $?
diff --git a/FWCore/Integration/test/inputExtSourceTest.sh b/FWCore/Integration/test/inputExtSourceTest.sh
index 7e9e9c1817c07..6db970829820d 100755
--- a/FWCore/Integration/test/inputExtSourceTest.sh
+++ b/FWCore/Integration/test/inputExtSourceTest.sh
@@ -2,4 +2,4 @@
function die { echo $1: status $2 ; exit $2; }
-cmsRun --parameter-set ${SCRAM_TEST_PATH}/inputExtSourceTest_cfg.py || die 'Failed in inputExtSourceTest_cfg.py' $?
+cmsRun ${SCRAM_TEST_PATH}/inputExtSourceTest_cfg.py || die 'Failed in inputExtSourceTest_cfg.py' $?
diff --git a/FWCore/Integration/test/inputSourceTest.sh b/FWCore/Integration/test/inputSourceTest.sh
index 5a6dda3408bb7..777c2465c2256 100755
--- a/FWCore/Integration/test/inputSourceTest.sh
+++ b/FWCore/Integration/test/inputSourceTest.sh
@@ -2,4 +2,4 @@
function die { echo $1: status $2 ; exit $2; }
-cmsRun --parameter-set ${SCRAM_TEST_PATH}/inputSourceTest_cfg.py || die 'Failed in inputSourceTest_cfg.py' $?
+cmsRun ${SCRAM_TEST_PATH}/inputSourceTest_cfg.py || die 'Failed in inputSourceTest_cfg.py' $?
diff --git a/FWCore/Integration/test/newdetsetvector_t.sh b/FWCore/Integration/test/newdetsetvector_t.sh
index efa7113f796c1..efec717ed9816 100755
--- a/FWCore/Integration/test/newdetsetvector_t.sh
+++ b/FWCore/Integration/test/newdetsetvector_t.sh
@@ -2,6 +2,6 @@
function die { echo $1: status $2 ; exit $2; }
-cmsRun --parameter-set ${SCRAM_TEST_PATH}/newdetsetvector_t_cfg.py || die 'Failed in detsetvector_t_cfg.py' $?
+cmsRun ${SCRAM_TEST_PATH}/newdetsetvector_t_cfg.py || die 'Failed in detsetvector_t_cfg.py' $?
edmEventSize -A -v testDSTV.root
diff --git a/FWCore/Integration/test/parentlessTest.sh b/FWCore/Integration/test/parentlessTest.sh
index c1ee79ca6c1f1..3b969b7d6d017 100755
--- a/FWCore/Integration/test/parentlessTest.sh
+++ b/FWCore/Integration/test/parentlessTest.sh
@@ -2,4 +2,4 @@
function die { echo $1: status $2 ; exit $2; }
-cmsRun --parameter-set ${SCRAM_TEST_PATH}/parentlessTest_cfg.py || die 'Failed in parentlessTest_cfg.py' $?
+cmsRun ${SCRAM_TEST_PATH}/parentlessTest_cfg.py || die 'Failed in parentlessTest_cfg.py' $?
diff --git a/FWCore/Integration/test/refTest.sh b/FWCore/Integration/test/refTest.sh
index 6c19e208ad440..01afd34785215 100755
--- a/FWCore/Integration/test/refTest.sh
+++ b/FWCore/Integration/test/refTest.sh
@@ -5,10 +5,10 @@ function die { echo $1: status $2 ; exit $2; }
LOCAL_TEST_DIR=${SCRAM_TEST_PATH}
echo cmsRun RefTest_cfg.py
-cmsRun --parameter-set ${LOCAL_TEST_DIR}/RefTest_cfg.py || die 'Failed in RefTest_cfg.py' $?
+cmsRun ${LOCAL_TEST_DIR}/RefTest_cfg.py || die 'Failed in RefTest_cfg.py' $?
echo cmsRun AssociationMapTest_cfg.py
-cmsRun --parameter-set ${LOCAL_TEST_DIR}/AssociationMapTest_cfg.py || die 'Failed in AssociationMapTest_cfg.py' $?
+cmsRun ${LOCAL_TEST_DIR}/AssociationMapTest_cfg.py || die 'Failed in AssociationMapTest_cfg.py' $?
echo cmsRun AssociationMapReadTest_cfg.py
-cmsRun --parameter-set ${LOCAL_TEST_DIR}/AssociationMapReadTest_cfg.py || die 'Failed in AssociationMapReadTest_cfg.py' $?
+cmsRun ${LOCAL_TEST_DIR}/AssociationMapReadTest_cfg.py || die 'Failed in AssociationMapReadTest_cfg.py' $?
diff --git a/FWCore/Integration/test/run_ParameterSet.sh b/FWCore/Integration/test/run_ParameterSet.sh
index b7cae9f932964..37e32eb9ff2e5 100755
--- a/FWCore/Integration/test/run_ParameterSet.sh
+++ b/FWCore/Integration/test/run_ParameterSet.sh
@@ -8,17 +8,17 @@ LOCAL_TEST_DIR=${SCRAM_TEST_PATH}
# Intentionally fails because of an illegal parameter in a module.
echo ${test} ------------------------------------------------------------
- cmsRun -p ${LOCAL_TEST_DIR}/${test}_cfg.py 2> ${test}.txt
+ cmsRun ${LOCAL_TEST_DIR}/${test}_cfg.py 2> ${test}.txt
grep "Illegal parameter" ${test}.txt || die "cmsRun ${test}_cfg.py" $?
# Intentionally fails because of an illegal parameter in a source.
echo testIllegalSourceParameter_cfg.py ------------------------------------------------------------
- cmsRun -p ${LOCAL_TEST_DIR}/testIllegalSourceParameter_cfg.py 2> testIllegalSourceParameter_cfg.txt
+ cmsRun ${LOCAL_TEST_DIR}/testIllegalSourceParameter_cfg.py 2> testIllegalSourceParameter_cfg.txt
grep "Illegal parameter" testIllegalSourceParameter_cfg.txt || die "cmsRun testIllegalSourceParameter_cfg.py" $?
# Intentionally fails because of an illegal parameter in a service.
echo testIllegalServiceParameter_cfg.py ------------------------------------------------------------
- cmsRun -p ${LOCAL_TEST_DIR}/testIllegalServiceParameter_cfg.py 2> testIllegalServiceParameter_cfg.txt
+ cmsRun ${LOCAL_TEST_DIR}/testIllegalServiceParameter_cfg.py 2> testIllegalServiceParameter_cfg.txt
grep "Illegal parameter" testIllegalServiceParameter_cfg.txt || die "cmsRun testIllegalServiceParameter_cfg.py" $?
# Note that DoodadESSource and WhatsItESProducer classes contain little tests for
@@ -31,7 +31,7 @@ LOCAL_TEST_DIR=${SCRAM_TEST_PATH}
# Make sure we can run using the cfi file generated in the previous process
echo cmsRun runAutoGeneratedCfi_cfg.py ------------------------------------------------------------
- cmsRun -p ${LOCAL_TEST_DIR}/runAutoGeneratedCfi_cfg.py || die "cmsRun runAutoGeneratedCfi_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/runAutoGeneratedCfi_cfg.py || die "cmsRun runAutoGeneratedCfi_cfg.py" $?
# Compare the cfi file to a reference file to ensure it is correct
diff ./testProducerWithPsetDesc_cfi.py ${LOCAL_TEST_DIR}/unit_test_outputs/testProducerWithPsetDesc_cfi.py || die "comparing testProducerWithPsetDesc_cfi.py" $?
@@ -39,11 +39,11 @@ LOCAL_TEST_DIR=${SCRAM_TEST_PATH}
# This time try a cfi without any of the required parameters to test that we properly insert
# required missing parameters into the ParameterSet
echo cmsRun runNotAutoGeneratedCfi_cfg.py ------------------------------------------------------------
- cmsRun -p ${LOCAL_TEST_DIR}/runNotAutoGeneratedCfi_cfg.py || die "cmsRun runNotAutoGeneratedCfi_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/runNotAutoGeneratedCfi_cfg.py || die "cmsRun runNotAutoGeneratedCfi_cfg.py" $?
# Compare the output of the PSetAnalyzer with a reference file
echo cmsRun testPSetAnalyzer_cfg.py ------------------------------------------------------------
- cmsRun -p ${LOCAL_TEST_DIR}/testPSetAnalyzer_cfg.py 2>&1 | grep " PSet test " > testPSetAnalyzer.txt
+ cmsRun ${LOCAL_TEST_DIR}/testPSetAnalyzer_cfg.py 2>&1 | grep " PSet test " > testPSetAnalyzer.txt
diff ./testPSetAnalyzer.txt ${LOCAL_TEST_DIR}/unit_test_outputs/testPSetAnalyzer.txt || die "comparing testPSetAnalyzer.txt" $?
# Print human readable from the ParameterSetDescription
@@ -67,13 +67,13 @@ LOCAL_TEST_DIR=${SCRAM_TEST_PATH}
# Test for errors and success when importing a restricted file in various ways
echo cmsRun importRestrictions1.py ------------------------------------------------------------
- cmsRun -p ${LOCAL_TEST_DIR}/importRestrictions1.py 2> importRestrictions1.txt
+ cmsRun ${LOCAL_TEST_DIR}/importRestrictions1.py 2> importRestrictions1.txt
grep "Event 2" importRestrictions1.txt || die " cmsRun importRestrictions1.py" $?
echo cmsRun importRestrictions2.py ------------------------------------------------------------
- cmsRun -p ${LOCAL_TEST_DIR}/importRestrictions2.py 2> importRestrictions2.txt
+ cmsRun ${LOCAL_TEST_DIR}/importRestrictions2.py 2> importRestrictions2.txt
grep "ImportError" importRestrictions2.txt || die " cmsRun importRestrictions2.py" $?
echo cmsRun importRestrictions3.py ------------------------------------------------------------
- cmsRun -p ${LOCAL_TEST_DIR}/importRestrictions3.py 2> importRestrictions3.txt
+ cmsRun ${LOCAL_TEST_DIR}/importRestrictions3.py 2> importRestrictions3.txt
grep "Event 2" importRestrictions3.txt || die " cmsRun importRestrictions3.py" $?
exit 0
diff --git a/FWCore/Integration/test/run_ParentageWithStreamerIO.sh b/FWCore/Integration/test/run_ParentageWithStreamerIO.sh
index cfe782e460353..adc795078fec9 100755
--- a/FWCore/Integration/test/run_ParentageWithStreamerIO.sh
+++ b/FWCore/Integration/test/run_ParentageWithStreamerIO.sh
@@ -7,12 +7,12 @@ function die { echo Failure $1: status $2 ; exit $2 ; }
LOCAL_TEST_DIR=${SCRAM_TEST_PATH}
echo ${test}_1_cfg.py
- cmsRun -p ${LOCAL_TEST_DIR}/${test}_1_cfg.py || die "cmsRun ${test}_1_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/${test}_1_cfg.py || die "cmsRun ${test}_1_cfg.py" $?
echo ${test}_2_cfg.py
- cmsRun -p ${LOCAL_TEST_DIR}/${test}_2_cfg.py || die "cmsRun ${test}_2_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/${test}_2_cfg.py || die "cmsRun ${test}_2_cfg.py" $?
echo ${test}_3_cfg.py
- cmsRun -p ${LOCAL_TEST_DIR}/${test}_3_cfg.py || die "cmsRun ${test}_3_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/${test}_3_cfg.py || die "cmsRun ${test}_3_cfg.py" $?
exit 0
diff --git a/FWCore/Integration/test/run_RefAlias.sh b/FWCore/Integration/test/run_RefAlias.sh
index c00e2d443e853..7dc516879e7cb 100755
--- a/FWCore/Integration/test/run_RefAlias.sh
+++ b/FWCore/Integration/test/run_RefAlias.sh
@@ -6,15 +6,15 @@ function die { echo Failure $1: status $2 ; exit $2 ; }
LOCAL_TEST_DIR=${SCRAM_TEST_PATH}
echo ${test}drop_alias_cfg.py ------------------------------------------------------------
- cmsRun -p ${LOCAL_TEST_DIR}/${test}drop_alias_cfg.py || die "cmsRun ${test}drop_alias_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/${test}drop_alias_cfg.py || die "cmsRun ${test}drop_alias_cfg.py" $?
echo ${test}drop_original_cfg.py ------------------------------------------------------------
- cmsRun -p ${LOCAL_TEST_DIR}/${test}drop_original_cfg.py || die "cmsRun ${test}drop_original_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/${test}drop_original_cfg.py || die "cmsRun ${test}drop_original_cfg.py" $?
echo ${test}read_alias_cfg.py------------------------------------------------------------
- cmsRun -p ${LOCAL_TEST_DIR}/${test}read_alias_cfg.py || die "cmsRun ${test}read_alias_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/${test}read_alias_cfg.py || die "cmsRun ${test}read_alias_cfg.py" $?
echo ${test}read_original_cfg.py------------------------------------------------------------
- cmsRun -p ${LOCAL_TEST_DIR}/${test}read_original_cfg.py || die "cmsRun ${test}read_original_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/${test}read_original_cfg.py || die "cmsRun ${test}read_original_cfg.py" $?
exit 0
diff --git a/FWCore/Integration/test/run_RefMerge.sh b/FWCore/Integration/test/run_RefMerge.sh
index f8533d2643715..d1643036544a2 100755
--- a/FWCore/Integration/test/run_RefMerge.sh
+++ b/FWCore/Integration/test/run_RefMerge.sh
@@ -6,18 +6,18 @@ function die { echo Failure $1: status $2 ; exit $2 ; }
LOCAL_TEST_DIR=${SCRAM_TEST_PATH}
echo ${test}prod1 ------------------------------------------------------------
- cmsRun -p ${LOCAL_TEST_DIR}/${test}prod1_cfg.py || die "cmsRun ${test}prod1_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/${test}prod1_cfg.py || die "cmsRun ${test}prod1_cfg.py" $?
echo ${test}prod2 ------------------------------------------------------------
- cmsRun -p ${LOCAL_TEST_DIR}/${test}prod2_cfg.py || die "cmsRun ${test}prod2_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/${test}prod2_cfg.py || die "cmsRun ${test}prod2_cfg.py" $?
echo ${test}MERGE------------------------------------------------------------
- cmsRun -p ${LOCAL_TEST_DIR}/${test}cfg.py || die "cmsRun ${test}cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/${test}cfg.py || die "cmsRun ${test}cfg.py" $?
echo ${test}test------------------------------------------------------------
- cmsRun -p ${LOCAL_TEST_DIR}/${test}test_cfg.py || die "cmsRun ${test}test_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/${test}test_cfg.py || die "cmsRun ${test}test_cfg.py" $?
echo ${test}test------------------------------------------------------------
- cmsRun -p ${LOCAL_TEST_DIR}/${test}subprocess_cfg.py || die "cmsRun ${test}subprocess_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/${test}subprocess_cfg.py || die "cmsRun ${test}subprocess_cfg.py" $?
exit 0
diff --git a/FWCore/Integration/test/run_RunMerge.sh b/FWCore/Integration/test/run_RunMerge.sh
index aafb8f3c86456..abe70fff3c628 100755
--- a/FWCore/Integration/test/run_RunMerge.sh
+++ b/FWCore/Integration/test/run_RunMerge.sh
@@ -6,114 +6,114 @@ function die { echo Failure $1: status $2 ; exit $2 ; }
LOCAL_TEST_DIR=${SCRAM_TEST_PATH}
echo ${test}PROD0 ------------------------------------------------------------
- cmsRun -p ${LOCAL_TEST_DIR}/${test}PROD0_cfg.py || die "cmsRun ${test}PROD0_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/${test}PROD0_cfg.py || die "cmsRun ${test}PROD0_cfg.py" $?
echo ${test}PROD1 ------------------------------------------------------------
- cmsRun -p ${LOCAL_TEST_DIR}/${test}PROD1_cfg.py || die "cmsRun ${test}PROD1_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/${test}PROD1_cfg.py || die "cmsRun ${test}PROD1_cfg.py" $?
echo ${test}PROD2------------------------------------------------------------
- cmsRun -p ${LOCAL_TEST_DIR}/${test}PROD2_cfg.py || die "cmsRun ${test}PROD2_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/${test}PROD2_cfg.py || die "cmsRun ${test}PROD2_cfg.py" $?
echo ${test}PROD2EXTRA------------------------------------------------------------
- cmsRun -p ${LOCAL_TEST_DIR}/${test}PROD2EXTRA_cfg.py || die "cmsRun ${test}PROD2EXTRA_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/${test}PROD2EXTRA_cfg.py || die "cmsRun ${test}PROD2EXTRA_cfg.py" $?
echo ${test}PROD3------------------------------------------------------------
- cmsRun -p ${LOCAL_TEST_DIR}/${test}PROD3_cfg.py || die "cmsRun ${test}PROD3_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/${test}PROD3_cfg.py || die "cmsRun ${test}PROD3_cfg.py" $?
echo ${test}PROD3EXTRA------------------------------------------------------------
- cmsRun -p ${LOCAL_TEST_DIR}/${test}PROD3EXTRA_cfg.py || die "cmsRun ${test}PROD3EXTRA_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/${test}PROD3EXTRA_cfg.py || die "cmsRun ${test}PROD3EXTRA_cfg.py" $?
echo ${test}PROD4------------------------------------------------------------
- cmsRun -p ${LOCAL_TEST_DIR}/${test}PROD4_cfg.py || die "cmsRun ${test}PROD4_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/${test}PROD4_cfg.py || die "cmsRun ${test}PROD4_cfg.py" $?
echo ${test}PROD5------------------------------------------------------------
- cmsRun -p ${LOCAL_TEST_DIR}/${test}PROD5_cfg.py || die "cmsRun ${test}PROD5_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/${test}PROD5_cfg.py || die "cmsRun ${test}PROD5_cfg.py" $?
echo ${test}PROD6------------------------------------------------------------
- cmsRun -p ${LOCAL_TEST_DIR}/${test}PROD6_cfg.py || die "cmsRun ${test}PROD6_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/${test}PROD6_cfg.py || die "cmsRun ${test}PROD6_cfg.py" $?
echo ${test}PROD7------------------------------------------------------------
- cmsRun -p ${LOCAL_TEST_DIR}/${test}PROD7_cfg.py || die "cmsRun ${test}PROD7_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/${test}PROD7_cfg.py || die "cmsRun ${test}PROD7_cfg.py" $?
echo ${test}PROD11------------------------------------------------------------
- cmsRun -p ${LOCAL_TEST_DIR}/${test}PROD11_cfg.py || die "cmsRun ${test}PROD11_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/${test}PROD11_cfg.py || die "cmsRun ${test}PROD11_cfg.py" $?
echo ${test}MERGE------------------------------------------------------------
- cmsRun -p ${LOCAL_TEST_DIR}/${test}MERGE_cfg.py || die "cmsRun ${test}MERGE_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/${test}MERGE_cfg.py || die "cmsRun ${test}MERGE_cfg.py" $?
echo ${test}MERGE1------------------------------------------------------------
- cmsRun -p ${LOCAL_TEST_DIR}/${test}MERGE1_cfg.py || die "cmsRun ${test}MERGE1_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/${test}MERGE1_cfg.py || die "cmsRun ${test}MERGE1_cfg.py" $?
echo ${test}MERGE2------------------------------------------------------------
- cmsRun -p ${LOCAL_TEST_DIR}/${test}MERGE2_cfg.py || die "cmsRun ${test}MERGE2_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/${test}MERGE2_cfg.py || die "cmsRun ${test}MERGE2_cfg.py" $?
echo ${test}MERGE3------------------------------------------------------------
- cmsRun -p ${LOCAL_TEST_DIR}/${test}MERGE3_cfg.py || die "cmsRun ${test}MERGE3_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/${test}MERGE3_cfg.py || die "cmsRun ${test}MERGE3_cfg.py" $?
echo ${test}MERGE3x------------------------------------------------------------
- cmsRun -p ${LOCAL_TEST_DIR}/${test}MERGE3x_cfg.py || die "cmsRun ${test}MERGE3x_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/${test}MERGE3x_cfg.py || die "cmsRun ${test}MERGE3x_cfg.py" $?
echo ${test}MERGE4------------------------------------------------------------
- cmsRun -p ${LOCAL_TEST_DIR}/${test}MERGE4_cfg.py || die "cmsRun ${test}MERGE4_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/${test}MERGE4_cfg.py || die "cmsRun ${test}MERGE4_cfg.py" $?
echo ${test}MERGE5------------------------------------------------------------
- cmsRun -p ${LOCAL_TEST_DIR}/${test}MERGE5_cfg.py || die "cmsRun ${test}MERGE5_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/${test}MERGE5_cfg.py || die "cmsRun ${test}MERGE5_cfg.py" $?
echo ${test}TEST------------------------------------------------------------
- cmsRun -p ${LOCAL_TEST_DIR}/${test}TEST_cfg.py || die "cmsRun ${test}TEST_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/${test}TEST_cfg.py || die "cmsRun ${test}TEST_cfg.py" $?
echo ${test}TESTFAIL------------------------------------------------------------
- cmsRun -p ${LOCAL_TEST_DIR}/${test}TESTFAIL_cfg.py 2>/dev/null && die "cmsRun ${test}TESTFAIL_cfg.py" 1
+ cmsRun ${LOCAL_TEST_DIR}/${test}TESTFAIL_cfg.py 2>/dev/null && die "cmsRun ${test}TESTFAIL_cfg.py" 1
echo ${test}TEST1------------------------------------------------------------
- cmsRun -p ${LOCAL_TEST_DIR}/${test}TEST1_cfg.py || die "cmsRun ${test}TEST1_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/${test}TEST1_cfg.py || die "cmsRun ${test}TEST1_cfg.py" $?
echo ${test}TEST2------------------------------------------------------------
- cmsRun -p ${LOCAL_TEST_DIR}/${test}TEST2_cfg.py || die "cmsRun ${test}TEST2_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/${test}TEST2_cfg.py || die "cmsRun ${test}TEST2_cfg.py" $?
echo ${test}TEST3------------------------------------------------------------
- cmsRun -p ${LOCAL_TEST_DIR}/${test}TEST3_cfg.py || die "cmsRun ${test}TEST3_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/${test}TEST3_cfg.py || die "cmsRun ${test}TEST3_cfg.py" $?
echo ${test}TEST4------------------------------------------------------------
- cmsRun -p ${LOCAL_TEST_DIR}/${test}TEST4_cfg.py || die "cmsRun ${test}TEST4_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/${test}TEST4_cfg.py || die "cmsRun ${test}TEST4_cfg.py" $?
echo ${test}TEST5------------------------------------------------------------
- cmsRun -p ${LOCAL_TEST_DIR}/${test}TEST5_cfg.py || die "cmsRun ${test}TEST5_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/${test}TEST5_cfg.py || die "cmsRun ${test}TEST5_cfg.py" $?
echo ${test}TEST11------------------------------------------------------------
- cmsRun -p ${LOCAL_TEST_DIR}/${test}TEST11_cfg.py || die "cmsRun ${test}TEST11_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/${test}TEST11_cfg.py || die "cmsRun ${test}TEST11_cfg.py" $?
echo ${test}COPY------------------------------------------------------------
- cmsRun -p ${LOCAL_TEST_DIR}/${test}COPY_cfg.py || die "cmsRun ${test}COPY_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/${test}COPY_cfg.py || die "cmsRun ${test}COPY_cfg.py" $?
echo ${test}COPY1------------------------------------------------------------
- cmsRun -p ${LOCAL_TEST_DIR}/${test}COPY1_cfg.py || die "cmsRun ${test}COPY1_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/${test}COPY1_cfg.py || die "cmsRun ${test}COPY1_cfg.py" $?
echo ${test}MERGE6------------------------------------------------------------
- cmsRun -p ${LOCAL_TEST_DIR}/${test}MERGE6_cfg.py || die "cmsRun ${test}MERGE6_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/${test}MERGE6_cfg.py || die "cmsRun ${test}MERGE6_cfg.py" $?
echo ${test}NoRunLumiSort------------------------------------------------------------
- cmsRun -p ${LOCAL_TEST_DIR}/${test}NoRunLumiSort_cfg.py || die "cmsRun ${test}NoRunLumiSort_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/${test}NoRunLumiSort_cfg.py || die "cmsRun ${test}NoRunLumiSort_cfg.py" $?
echo ${test}TEST6------------------------------------------------------------
- cmsRun -p ${LOCAL_TEST_DIR}/${test}TEST6_cfg.py || die "cmsRun ${test}TEST6_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/${test}TEST6_cfg.py || die "cmsRun ${test}TEST6_cfg.py" $?
echo ${test}PickEvents------------------------------------------------------------
- cmsRun -p ${LOCAL_TEST_DIR}/${test}PickEvents_cfg.py || die "cmsRun ${test}PickEvents_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/${test}PickEvents_cfg.py || die "cmsRun ${test}PickEvents_cfg.py" $?
echo ${test}PickEventsx------------------------------------------------------------
- cmsRun -p ${LOCAL_TEST_DIR}/${test}PickEventsx_cfg.py || die "cmsRun ${test}PickEventsx_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/${test}PickEventsx_cfg.py || die "cmsRun ${test}PickEventsx_cfg.py" $?
echo ${test}FastCloning------------------------------------------------------------
- cmsRun -p ${LOCAL_TEST_DIR}/${test}FastCloning_cfg.py 2> testFastCloning.txt
+ cmsRun ${LOCAL_TEST_DIR}/${test}FastCloning_cfg.py 2> testFastCloning.txt
grep "Another exception was caught" testFastCloning.txt || die "cmsRun testRunMergeFastCloning_cfg.py" $?
echo testLooperEventNavigation-----------------------------------------------------
- cmsRun -p ${LOCAL_TEST_DIR}/testLooperEventNavigation_cfg.py < ${LOCAL_TEST_DIR}/testLooperEventNavigation.txt > testLooperEventNavigationOutput.txt || die "cmsRun testLooperEventNavigation_cfg.py " $?
+ cmsRun ${LOCAL_TEST_DIR}/testLooperEventNavigation_cfg.py < ${LOCAL_TEST_DIR}/testLooperEventNavigation.txt > testLooperEventNavigationOutput.txt || die "cmsRun testLooperEventNavigation_cfg.py " $?
diff ${LOCAL_TEST_DIR}/unit_test_outputs/testLooperEventNavigationOutput.txt testLooperEventNavigationOutput.txt || die "comparing testLooperEventNavigationOutput.txt" $?
echo testLooperEventNavigation1-----------------------------------------------------
- cmsRun -p ${LOCAL_TEST_DIR}/testLooperEventNavigation1_cfg.py < ${LOCAL_TEST_DIR}/testLooperEventNavigation.txt > testLooperEventNavigationOutput1.txt || die "cmsRun testLooperEventNavigation1_cfg.py " $?
+ cmsRun ${LOCAL_TEST_DIR}/testLooperEventNavigation1_cfg.py < ${LOCAL_TEST_DIR}/testLooperEventNavigation.txt > testLooperEventNavigationOutput1.txt || die "cmsRun testLooperEventNavigation1_cfg.py " $?
diff ${LOCAL_TEST_DIR}/unit_test_outputs/testLooperEventNavigationOutput.txt testLooperEventNavigationOutput1.txt || die "comparing testLooperEventNavigationOutput1.txt" $?
exit 0
diff --git a/FWCore/Integration/test/run_RunMerge2.sh b/FWCore/Integration/test/run_RunMerge2.sh
index ee7290ba4e8a6..edc9b8124f0f2 100755
--- a/FWCore/Integration/test/run_RunMerge2.sh
+++ b/FWCore/Integration/test/run_RunMerge2.sh
@@ -6,45 +6,45 @@ function die { echo Failure $1: status $2 ; exit $2 ; }
LOCAL_TEST_DIR=${SCRAM_TEST_PATH}
echo ${test}PROD100 ------------------------------------------------------------
- cmsRun -p ${LOCAL_TEST_DIR}/${test}PROD100_cfg.py || die "cmsRun ${test}PROD100_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/${test}PROD100_cfg.py || die "cmsRun ${test}PROD100_cfg.py" $?
echo ${test}PROD101 ------------------------------------------------------------
- cmsRun -p ${LOCAL_TEST_DIR}/${test}PROD101_cfg.py || die "cmsRun ${test}PROD101_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/${test}PROD101_cfg.py || die "cmsRun ${test}PROD101_cfg.py" $?
echo ${test}PROD102 ------------------------------------------------------------
- cmsRun -p ${LOCAL_TEST_DIR}/${test}PROD102_cfg.py || die "cmsRun ${test}PROD102_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/${test}PROD102_cfg.py || die "cmsRun ${test}PROD102_cfg.py" $?
echo ${test}SPLIT100 ------------------------------------------------------------
- cmsRun -p ${LOCAL_TEST_DIR}/${test}SPLIT100_cfg.py || die "cmsRun ${test}SPLIT100_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/${test}SPLIT100_cfg.py || die "cmsRun ${test}SPLIT100_cfg.py" $?
echo ${test}SPLIT101 ------------------------------------------------------------
- cmsRun -p ${LOCAL_TEST_DIR}/${test}SPLIT101_cfg.py || die "cmsRun ${test}SPLIT101_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/${test}SPLIT101_cfg.py || die "cmsRun ${test}SPLIT101_cfg.py" $?
echo ${test}SPLIT102 ------------------------------------------------------------
- cmsRun -p ${LOCAL_TEST_DIR}/${test}SPLIT102_cfg.py || die "cmsRun ${test}SPLIT102_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/${test}SPLIT102_cfg.py || die "cmsRun ${test}SPLIT102_cfg.py" $?
echo ${test}SPLIT103 ------------------------------------------------------------
- cmsRun -p ${LOCAL_TEST_DIR}/${test}SPLIT103_cfg.py || die "cmsRun ${test}SPLIT103_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/${test}SPLIT103_cfg.py || die "cmsRun ${test}SPLIT103_cfg.py" $?
echo ${test}MERGE100 ------------------------------------------------------------
- cmsRun -p ${LOCAL_TEST_DIR}/${test}MERGE100_cfg.py || die "cmsRun ${test}MERGE100_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/${test}MERGE100_cfg.py || die "cmsRun ${test}MERGE100_cfg.py" $?
echo ${test}MERGE101 ------------------------------------------------------------
- cmsRun -p ${LOCAL_TEST_DIR}/${test}MERGE101_cfg.py || die "cmsRun ${test}MERGE101_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/${test}MERGE101_cfg.py || die "cmsRun ${test}MERGE101_cfg.py" $?
echo ${test}MERGE102 ------------------------------------------------------------
- cmsRun -p ${LOCAL_TEST_DIR}/${test}MERGE102_cfg.py || die "cmsRun ${test}MERGE102_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/${test}MERGE102_cfg.py || die "cmsRun ${test}MERGE102_cfg.py" $?
echo ${test}TEST100 ------------------------------------------------------------
- cmsRun -p ${LOCAL_TEST_DIR}/${test}TEST100_cfg.py || die "cmsRun ${test}TEST100_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/${test}TEST100_cfg.py || die "cmsRun ${test}TEST100_cfg.py" $?
echo ${test}TEST101 ------------------------------------------------------------
- cmsRun -p ${LOCAL_TEST_DIR}/${test}TEST101_cfg.py || die "cmsRun ${test}TEST101_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/${test}TEST101_cfg.py || die "cmsRun ${test}TEST101_cfg.py" $?
echo ${test}COPY100 ------------------------------------------------------------
- cmsRun -p ${LOCAL_TEST_DIR}/${test}COPY100_cfg.py || die "cmsRun ${test}COPY100_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/${test}COPY100_cfg.py || die "cmsRun ${test}COPY100_cfg.py" $?
echo ${test}COPY101 ------------------------------------------------------------
- cmsRun -p ${LOCAL_TEST_DIR}/${test}COPY101_cfg.py || die "cmsRun ${test}COPY101_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/${test}COPY101_cfg.py || die "cmsRun ${test}COPY101_cfg.py" $?
exit 0
diff --git a/FWCore/Integration/test/run_SeriesOfProcesses.sh b/FWCore/Integration/test/run_SeriesOfProcesses.sh
index c7fc3b66ec8f2..44e8fd9284293 100755
--- a/FWCore/Integration/test/run_SeriesOfProcesses.sh
+++ b/FWCore/Integration/test/run_SeriesOfProcesses.sh
@@ -6,23 +6,23 @@ function die { echo Failure $1: status $2 ; exit $2 ; }
LOCAL_TEST_DIR=${SCRAM_TEST_PATH}
- cmsRun -p ${LOCAL_TEST_DIR}/${test}HLT_cfg.py || die "cmsRun ${test}HLT_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/${test}HLT_cfg.py || die "cmsRun ${test}HLT_cfg.py" $?
- cmsRun -p ${LOCAL_TEST_DIR}/${test}PROD_cfg.py || die "cmsRun ${test}PROD_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/${test}PROD_cfg.py || die "cmsRun ${test}PROD_cfg.py" $?
- cmsRun -p ${LOCAL_TEST_DIR}/${test}TEST_cfg.py || die "cmsRun ${test}TEST_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/${test}TEST_cfg.py || die "cmsRun ${test}TEST_cfg.py" $?
- cmsRun -p ${LOCAL_TEST_DIR}/${test}TEST1_cfg.py || die "cmsRun ${test}TEST1_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/${test}TEST1_cfg.py || die "cmsRun ${test}TEST1_cfg.py" $?
- cmsRun -p ${LOCAL_TEST_DIR}/${test}TEST2_cfg.py 2> ${test}TEST2.txt
+ cmsRun ${LOCAL_TEST_DIR}/${test}TEST2_cfg.py 2> ${test}TEST2.txt
grep "Duplicate Process" ${test}TEST2.txt || die "cmsRun ${test}TEST2_cfg.py" $?
- cmsRun -p ${LOCAL_TEST_DIR}/${test}TEST3_cfg.py || die "Failure in history testing in ${test}" $?
+ cmsRun ${LOCAL_TEST_DIR}/${test}TEST3_cfg.py || die "Failure in history testing in ${test}" $?
- cmsRun -p ${LOCAL_TEST_DIR}/${test}PROD2TEST_cfg.py || die "cmsRun ${test}PROD2TEST_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/${test}PROD2TEST_cfg.py || die "cmsRun ${test}PROD2TEST_cfg.py" $?
- cmsRun -p ${LOCAL_TEST_DIR}/${test}PROD3TEST_cfg.py || die "cmsRun ${test}PROD3TEST_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/${test}PROD3TEST_cfg.py || die "cmsRun ${test}PROD3TEST_cfg.py" $?
- cmsRun -p ${LOCAL_TEST_DIR}/${test}PROD2TEST_unscheduled_cfg.py || die "cmsRun ${test}PROD2TEST_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/${test}PROD2TEST_unscheduled_cfg.py || die "cmsRun ${test}PROD2TEST_cfg.py" $?
exit 0
diff --git a/FWCore/Integration/test/run_SubProcess.sh b/FWCore/Integration/test/run_SubProcess.sh
index 34b3af47bdef3..6d93783ad7045 100755
--- a/FWCore/Integration/test/run_SubProcess.sh
+++ b/FWCore/Integration/test/run_SubProcess.sh
@@ -10,32 +10,32 @@ LOCAL_TEST_DIR=${SCRAM_TEST_PATH}
rm -f ${test}.log
echo cmsRun testSubProcess_cfg.py
- cmsRun -p ${LOCAL_TEST_DIR}/${test}_cfg.py >& ${test}.log 2>&1 || die "cmsRun ${test}_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/${test}_cfg.py >& ${test}.log 2>&1 || die "cmsRun ${test}_cfg.py" $?
grep Doodad ${test}.log > testSubProcess.grep.txt
diff ${LOCAL_TEST_DIR}/unit_test_outputs/testSubProcess.grep.txt testSubProcess.grep.txt || die "comparing testSubProcess.grep.txt" $?
grep "^++" ${test}.log | grep -v "Disabling gnu" > testSubProcess.grep2.txt
diff ${LOCAL_TEST_DIR}/unit_test_outputs/testSubProcess.grep2.txt testSubProcess.grep2.txt || die "comparing testSubProcess.grep2.txt" $?
echo cmsRun readSubProcessOutput_cfg.py
- cmsRun -p ${LOCAL_TEST_DIR}/readSubProcessOutput_cfg.py || die "cmsRun readSubProcessOutput_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/readSubProcessOutput_cfg.py || die "cmsRun readSubProcessOutput_cfg.py" $?
echo cmsRun testSubProcessEventSetup_cfg.py
- cmsRun -p ${LOCAL_TEST_DIR}/testSubProcessEventSetup_cfg.py > testSubProcessEventSetup.log 2>&1 || die "cmsRun testSubProcessEventSetup_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/testSubProcessEventSetup_cfg.py > testSubProcessEventSetup.log 2>&1 || die "cmsRun testSubProcessEventSetup_cfg.py" $?
grep "Sharing" testSubProcessEventSetup.log > testSubProcessEventSetup.grep.txt
diff ${LOCAL_TEST_DIR}/unit_test_outputs/testSubProcessEventSetup.grep.txt testSubProcessEventSetup.grep.txt || die "comparing testSubProcessEventSetup.grep.txt" $?
echo cmsRun testSubProcessEventSetup1_cfg.py
- cmsRun -p ${LOCAL_TEST_DIR}/testSubProcessEventSetup1_cfg.py > testSubProcessEventSetup1.log 2>&1 || die "cmsRun testSubProcessEventSetup1_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/testSubProcessEventSetup1_cfg.py > testSubProcessEventSetup1.log 2>&1 || die "cmsRun testSubProcessEventSetup1_cfg.py" $?
grep "ESTestAnalyzerB: p" testSubProcessEventSetup1.log > testSubProcessEventSetup1.grep.txt
grep "ESTestAnalyzerK: p" testSubProcessEventSetup1.log >> testSubProcessEventSetup1.grep.txt
grep "Sharing" testSubProcessEventSetup1.log >> testSubProcessEventSetup1.grep.txt
diff ${LOCAL_TEST_DIR}/unit_test_outputs/testSubProcessEventSetup1.grep.txt testSubProcessEventSetup1.grep.txt || die "comparing testSubProcessEventSetup1.grep.txt" $?
echo cmsRun testSubProcessUnscheduled_cfg.py
- cmsRun -p ${LOCAL_TEST_DIR}/testSubProcessUnscheduled_cfg.py || die "cmsRun testSubProcessUnscheduled_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/testSubProcessUnscheduled_cfg.py || die "cmsRun testSubProcessUnscheduled_cfg.py" $?
echo cmsRun testSubProcessUnscheduledRead_cfg.py
- cmsRun -p ${LOCAL_TEST_DIR}/testSubProcessUnscheduledRead_cfg.py || die "cmsRun testSubProcessUnscheduledRead_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/testSubProcessUnscheduledRead_cfg.py || die "cmsRun testSubProcessUnscheduledRead_cfg.py" $?
exit 0
diff --git a/FWCore/Integration/test/run_TestDropOnInput.sh b/FWCore/Integration/test/run_TestDropOnInput.sh
index 6abafd263f359..ecd413cffc68d 100755
--- a/FWCore/Integration/test/run_TestDropOnInput.sh
+++ b/FWCore/Integration/test/run_TestDropOnInput.sh
@@ -7,31 +7,31 @@ function die { echo Failure $1: status $2 ; exit $2 ; }
LOCAL_TEST_DIR=${SCRAM_TEST_PATH}
echo "testDropOnInput1_1"
- cmsRun -p ${LOCAL_TEST_DIR}/${test}1_1_cfg.py || die "cmsRun ${test}1_1_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/${test}1_1_cfg.py || die "cmsRun ${test}1_1_cfg.py" $?
echo "testDropOnInput1_2"
- cmsRun -p ${LOCAL_TEST_DIR}/${test}1_2_cfg.py || die "cmsRun ${test}1_2_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/${test}1_2_cfg.py || die "cmsRun ${test}1_2_cfg.py" $?
echo "testDropOnInput2"
- cmsRun -p ${LOCAL_TEST_DIR}/${test}2_cfg.py || die "cmsRun ${test}2_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/${test}2_cfg.py || die "cmsRun ${test}2_cfg.py" $?
echo "testDropOnInput3"
- cmsRun -p ${LOCAL_TEST_DIR}/${test}3_cfg.py || die "cmsRun ${test}3_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/${test}3_cfg.py || die "cmsRun ${test}3_cfg.py" $?
echo "testDropOnInputRead2"
- cmsRun -p ${LOCAL_TEST_DIR}/${test}Read2_cfg.py || die "cmsRun ${test}Read2_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/${test}Read2_cfg.py || die "cmsRun ${test}Read2_cfg.py" $?
echo "testDropOnInputRead2001"
- cmsRun -p ${LOCAL_TEST_DIR}/${test}Read2001_cfg.py || die "cmsRun ${test}Read2001_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/${test}Read2001_cfg.py || die "cmsRun ${test}Read2001_cfg.py" $?
echo "testDropOnInputRead3"
- cmsRun -p ${LOCAL_TEST_DIR}/${test}Read3_cfg.py || die "cmsRun ${test}Read3_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/${test}Read3_cfg.py || die "cmsRun ${test}Read3_cfg.py" $?
echo "testDropOnInputSubProcess_cfg.py"
- cmsRun -p ${LOCAL_TEST_DIR}/${test}SubProcess_cfg.py || die "cmsRun ${test}SubProcess_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/${test}SubProcess_cfg.py || die "cmsRun ${test}SubProcess_cfg.py" $?
echo "testDropOnInputReadSubProcess_cfg.py"
- cmsRun -p ${LOCAL_TEST_DIR}/${test}ReadSubProcess_cfg.py || die "cmsRun ${test}ReadSubProcess_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/${test}ReadSubProcess_cfg.py || die "cmsRun ${test}ReadSubProcess_cfg.py" $?
exit 0
diff --git a/FWCore/Integration/test/run_TestGetBy.sh b/FWCore/Integration/test/run_TestGetBy.sh
index 6fdb8d4512c15..143ae130c44f1 100755
--- a/FWCore/Integration/test/run_TestGetBy.sh
+++ b/FWCore/Integration/test/run_TestGetBy.sh
@@ -7,20 +7,20 @@ function die { echo Failure $1: status $2 ; exit $2 ; }
LOCAL_TEST_DIR=${SCRAM_TEST_PATH}
echo "testGetBy1"
- cmsRun -p ${LOCAL_TEST_DIR}/${test}1_cfg.py > testGetBy1.log 2>/dev/null || die "cmsRun ${test}1_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/${test}1_cfg.py > testGetBy1.log 2>/dev/null || die "cmsRun ${test}1_cfg.py" $?
grep -v "LegacyModules" testGetBy1.log > testGetBy1_1.log
diff ${LOCAL_TEST_DIR}/unit_test_outputs/testGetBy1.log testGetBy1_1.log || die "comparing testGetBy1.log" $?
echo "testGetBy2"
- cmsRun -p ${LOCAL_TEST_DIR}/${test}2_cfg.py > testGetBy2.log 2>/dev/null || die "cmsRun ${test}2_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/${test}2_cfg.py > testGetBy2.log 2>/dev/null || die "cmsRun ${test}2_cfg.py" $?
grep -v 'Initiating request to open file\|Successfully opened file\|Closed file\|LegacyModules' testGetBy2.log > testGetBy2_1.log
diff ${LOCAL_TEST_DIR}/unit_test_outputs/testGetBy2.log testGetBy2_1.log || die "comparing testGetBy2.log" $?
echo "testGetBy3"
- cmsRun -p ${LOCAL_TEST_DIR}/${test}3_cfg.py || die "cmsRun ${test}3_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/${test}3_cfg.py || die "cmsRun ${test}3_cfg.py" $?
echo "testConsumesInfo"
- cmsRun -p ${LOCAL_TEST_DIR}/testConsumesInfo_cfg.py > testConsumesInfo.log 2>/dev/null || die "cmsRun testConsumesInfo_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/testConsumesInfo_cfg.py > testConsumesInfo.log 2>/dev/null || die "cmsRun testConsumesInfo_cfg.py" $?
grep -v '++\|LegacyModules' testConsumesInfo.log > testConsumesInfo_1.log
rm testConsumesInfo.log
rm testConsumesInfo.root
@@ -32,27 +32,27 @@ LOCAL_TEST_DIR=${SCRAM_TEST_PATH}
grep -q "Duplicate Process" testDuplicateProcess.log || die 'Failed to print out exception message for duplicate process name' $?
echo "testGetBy1Mod"
- cmsRun -p ${LOCAL_TEST_DIR}/${test}1Mod_cfg.py > testGetBy1Mod.log 2>/dev/null || die "cmsRun ${test}1Mod_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/${test}1Mod_cfg.py > testGetBy1Mod.log 2>/dev/null || die "cmsRun ${test}1Mod_cfg.py" $?
echo "testGetByMerge"
- cmsRun -p ${LOCAL_TEST_DIR}/${test}Merge_cfg.py > testGetByMerge.log 2>/dev/null || die "cmsRun ${test}Merge_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/${test}Merge_cfg.py > testGetByMerge.log 2>/dev/null || die "cmsRun ${test}Merge_cfg.py" $?
echo "testGetByPlaceholder"
- cmsRun -p ${LOCAL_TEST_DIR}/${test}Placeholder_cfg.py || die "cmsRun ${test}Placeholder_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/${test}Placeholder_cfg.py || die "cmsRun ${test}Placeholder_cfg.py" $?
echo "testProducesCollector"
- cmsRun -p ${LOCAL_TEST_DIR}/testProducesCollector_cfg.py || die "cmsRun testProducesCollector_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/testProducesCollector_cfg.py || die "cmsRun testProducesCollector_cfg.py" $?
echo "testGetByRunsMode_cfg.py"
- cmsRun -p ${LOCAL_TEST_DIR}/testGetByRunsMode_cfg.py || die "cmsRun testGetByRunsMode_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/testGetByRunsMode_cfg.py || die "cmsRun testGetByRunsMode_cfg.py" $?
echo "testGetByRunsLumisMode_cfg.py"
- cmsRun -p ${LOCAL_TEST_DIR}/testGetByRunsLumisMode_cfg.py || die "cmsRun testGetByRunsLumisMode_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/testGetByRunsLumisMode_cfg.py || die "cmsRun testGetByRunsLumisMode_cfg.py" $?
echo "testGetByWithEmptyRun_cfg.py"
- cmsRun -p ${LOCAL_TEST_DIR}/testGetByWithEmptyRun_cfg.py || die "cmsRun testGetByWithEmptyRun_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/testGetByWithEmptyRun_cfg.py || die "cmsRun testGetByWithEmptyRun_cfg.py" $?
echo "testGetterOfProductsWithOutputModule_cfg.py"
- cmsRun -p ${LOCAL_TEST_DIR}/testGetterOfProductsWithOutputModule_cfg.py || die "cmsRun testGetterOfProductsWithOutputModule_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/testGetterOfProductsWithOutputModule_cfg.py || die "cmsRun testGetterOfProductsWithOutputModule_cfg.py" $?
exit 0
diff --git a/FWCore/Integration/test/run_TestGetByLabel.sh b/FWCore/Integration/test/run_TestGetByLabel.sh
index 139a572cddcda..a5ff20c655e7d 100755
--- a/FWCore/Integration/test/run_TestGetByLabel.sh
+++ b/FWCore/Integration/test/run_TestGetByLabel.sh
@@ -15,10 +15,10 @@ TEST_PATH=${LOCALTOP}/src/FWCore/Integration/test
cmsRun ${TEST_PATH}/testGetByLabelStep1_cfg.py || die "Failed cmsRun testGetByLabel_step1_cfg.py" $1
cmsRun ${TEST_PATH}/testGetByLabelStep2_cfg.py || die "Failed cmsRun testGetByLabel_step2_cfg.py" $1
-cmsRun ${TEST_PATH}/testGetByLabelStep2_cfg.py -- --noConsumes || die "Failed cmsRun testGetByLabel_step2_cfg.py --noConsumes" $1
-cmsRun ${TEST_PATH}/testGetByLabelStep2_cfg.py -- --thing || die "Failed cmsRun testGetByLabel_step2_cfg.py --thing" $1
-cmsRun ${TEST_PATH}/testGetByLabelStep2_cfg.py -- --thing --noConsumes || die "Failed cmsRun testGetByLabel_step2_cfg.py --thing --noConsumes" $1
-cmsRun ${TEST_PATH}/testGetByLabelStep2_cfg.py -- --otherInt || die "Failed cmsRun testGetByLabel_step2_cfg.py --otherInt" $1
-cmsRun ${TEST_PATH}/testGetByLabelStep2_cfg.py -- --otherInt --noConsumes || die "Failed cmsRun testGetByLabel_step2_cfg.py --otherInt --noConsumes" $1
+cmsRun ${TEST_PATH}/testGetByLabelStep2_cfg.py --noConsumes || die "Failed cmsRun testGetByLabel_step2_cfg.py --noConsumes" $1
+cmsRun ${TEST_PATH}/testGetByLabelStep2_cfg.py --thing || die "Failed cmsRun testGetByLabel_step2_cfg.py --thing" $1
+cmsRun ${TEST_PATH}/testGetByLabelStep2_cfg.py --thing --noConsumes || die "Failed cmsRun testGetByLabel_step2_cfg.py --thing --noConsumes" $1
+cmsRun ${TEST_PATH}/testGetByLabelStep2_cfg.py --otherInt || die "Failed cmsRun testGetByLabel_step2_cfg.py --otherInt" $1
+cmsRun ${TEST_PATH}/testGetByLabelStep2_cfg.py --otherInt --noConsumes || die "Failed cmsRun testGetByLabel_step2_cfg.py --otherInt --noConsumes" $1
popd
diff --git a/FWCore/Integration/test/run_TestModuleTypeResolver.sh b/FWCore/Integration/test/run_TestModuleTypeResolver.sh
index d1686ebdf69ba..c497f998cda7f 100755
--- a/FWCore/Integration/test/run_TestModuleTypeResolver.sh
+++ b/FWCore/Integration/test/run_TestModuleTypeResolver.sh
@@ -21,14 +21,14 @@ function runFailure {
}
runSuccess ""
-runSuccess "-- --enableOther --expectOther"
-runSuccess "-- --enableOther --accelerators=cpu"
-runSuccess "-- --enableOther --setInResolver=cpu"
-runSuccess "-- --enableOther --setInResolver=other --expectOther"
-runSuccess "-- --enableOther --setInResolver=cpu --setInModule=other --expectOther"
-runSuccess "-- --enableOther --setInResolver=other --setInModule=cpu"
-runSuccess "-- --enableOther --setInModule=cpu"
+runSuccess "--enableOther --expectOther"
+runSuccess "--enableOther --accelerators=cpu"
+runSuccess "--enableOther --setInResolver=cpu"
+runSuccess "--enableOther --setInResolver=other --expectOther"
+runSuccess "--enableOther --setInResolver=cpu --setInModule=other --expectOther"
+runSuccess "--enableOther --setInResolver=other --setInModule=cpu"
+runSuccess "--enableOther --setInModule=cpu"
-runFailure "-- --setInResolver=other --expectOther"
-runFailure "-- --setInModule=other --expectOther"
-runFailure "-- --setInResolver=other --setInModule=cpu"
+runFailure "--setInResolver=other --expectOther"
+runFailure "--setInModule=other --expectOther"
+runFailure "--setInResolver=other --setInModule=cpu"
diff --git a/FWCore/Integration/test/run_TestOutput.sh b/FWCore/Integration/test/run_TestOutput.sh
index 2aa90cc5c485d..ce1f47af9c212 100755
--- a/FWCore/Integration/test/run_TestOutput.sh
+++ b/FWCore/Integration/test/run_TestOutput.sh
@@ -7,7 +7,7 @@ function die { echo Failure $1: status $2 ; exit $2 ; }
LOCAL_TEST_DIR=${SCRAM_TEST_PATH}
echo "testOutput1"
- cmsRun -p ${LOCAL_TEST_DIR}/${test}1_cfg.py 2> testOutput1.log || die "cmsRun ${test}1_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/${test}1_cfg.py 2> testOutput1.log || die "cmsRun ${test}1_cfg.py" $?
# Check that all the transitions that were supposed to occur
# in a global output module actually did occur
@@ -40,7 +40,7 @@ LOCAL_TEST_DIR=${SCRAM_TEST_PATH}
# Above we tested using EmptySource. Repeat reading a file using PoolSource
echo "testOutput2"
- cmsRun -p ${LOCAL_TEST_DIR}/${test}2_cfg.py 2> testOutput2.log || die "cmsRun ${test}2_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/${test}2_cfg.py 2> testOutput2.log || die "cmsRun ${test}2_cfg.py" $?
grep "global write event" testOutput2.log > /dev/null || die "grep failed to find 'global write event'" $?
grep "global writeLuminosityBlock" testOutput2.log > /dev/null || die "grep failed to find 'global writeLuminosityBlock'" $?
diff --git a/FWCore/Integration/test/run_TestProcessAccelerator.sh b/FWCore/Integration/test/run_TestProcessAccelerator.sh
index 7aa273228ee16..87254eba4343c 100755
--- a/FWCore/Integration/test/run_TestProcessAccelerator.sh
+++ b/FWCore/Integration/test/run_TestProcessAccelerator.sh
@@ -11,15 +11,15 @@ cmsRun ${LOCAL_TEST_DIR}/${test}_cfg.py || die "cmsRun ${test}_cfg.py" $?
echo "*************************************************"
echo "accelerators=*, enableTest2"
-cmsRun ${LOCAL_TEST_DIR}/${test}_cfg.py -- --enableTest2 || die "cmsRun ${test}_cfg.py -- --enableTest2" $?
+cmsRun ${LOCAL_TEST_DIR}/${test}_cfg.py --enableTest2 || die "cmsRun ${test}_cfg.py --enableTest2" $?
echo "*************************************************"
echo "accelerators=test1"
-cmsRun ${LOCAL_TEST_DIR}/${test}_cfg.py -- --accelerators=test1 || die "cmsRun ${test}_cfg.py -- --accelerators=test1" $?
+cmsRun ${LOCAL_TEST_DIR}/${test}_cfg.py --accelerators=test1 || die "cmsRun ${test}_cfg.py --accelerators=test1" $?
echo "*************************************************"
echo "accelerators=test2"
-cmsRun -j testProcessAccelerators_jobreport.xml ${LOCAL_TEST_DIR}/${test}_cfg.py -- --accelerators=test2 && die "cmsRun ${test}_cfg.py -- --accelerators=test2 did not fail" 1
+cmsRun -j testProcessAccelerators_jobreport.xml ${LOCAL_TEST_DIR}/${test}_cfg.py --accelerators=test2 && die "cmsRun ${test}_cfg.py --accelerators=test2 did not fail" 1
EXIT_CODE=$(edmFjrDump --exitCode testProcessAccelerators_jobreport.xml)
if [ "x${EXIT_CODE}" != "x8035" ]; then
echo "ProcessAccelerator test for unavailable accelerator reported exit code ${EXIT_CODE} which is different from the expected 8035"
@@ -28,8 +28,8 @@ fi
echo "*************************************************"
echo "accelerators=test1, enableTest2"
-cmsRun ${LOCAL_TEST_DIR}/${test}_cfg.py -- --accelerators=test1 --enableTest2 || die "cmsRun ${test}_cfg.py -- --accelerators=test1 --enableTest2" $?
+cmsRun ${LOCAL_TEST_DIR}/${test}_cfg.py --accelerators=test1 --enableTest2 || die "cmsRun ${test}_cfg.py --accelerators=test1 --enableTest2" $?
echo "*************************************************"
echo "accelerators=test2, enableTest2"
-cmsRun ${LOCAL_TEST_DIR}/${test}_cfg.py -- --accelerators=test2 --enableTest2 || die "cmsRun ${test}_cfg.py -- --accelerators=test2 --enableTest2" $?
+cmsRun ${LOCAL_TEST_DIR}/${test}_cfg.py --accelerators=test2 --enableTest2 || die "cmsRun ${test}_cfg.py --accelerators=test2 --enableTest2" $?
diff --git a/FWCore/Integration/test/run_TestProcessBlock.sh b/FWCore/Integration/test/run_TestProcessBlock.sh
index cab9f9d4d65d0..db32e6d7c7c83 100755
--- a/FWCore/Integration/test/run_TestProcessBlock.sh
+++ b/FWCore/Integration/test/run_TestProcessBlock.sh
@@ -21,7 +21,7 @@ function die { echo Failure $1: status $2 ; exit $2 ; }
if [ $1 -eq 1 ]
then
echo "testProcessBlock1"
- cmsRun -p ${LOCAL_TEST_DIR}/testProcessBlock1_cfg.py &> testProcessBlock1.log || die "cmsRun testProcessBlock1_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/testProcessBlock1_cfg.py &> testProcessBlock1.log || die "cmsRun testProcessBlock1_cfg.py" $?
# The MetaData ProcessBlock branch and the TTree should exist to hold the ProcessBlock
# data. The Events branch should not exist because there were not any ProcessBlock branches
@@ -36,25 +36,25 @@ fi
if [ $1 -eq 2 ]
then
echo "testProcessBlock2"
- cmsRun -p ${LOCAL_TEST_DIR}/testProcessBlock2_cfg.py &> testProcessBlock2.log || die "cmsRun testProcessBlock2_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/testProcessBlock2_cfg.py &> testProcessBlock2.log || die "cmsRun testProcessBlock2_cfg.py" $?
fi
if [ $1 -eq 3 ]
then
echo "testProcessBlock3"
- cmsRun -p ${LOCAL_TEST_DIR}/testProcessBlock3_cfg.py &> testProcessBlock3.log || die "cmsRun testProcessBlock3_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/testProcessBlock3_cfg.py &> testProcessBlock3.log || die "cmsRun testProcessBlock3_cfg.py" $?
fi
if [ $1 -eq 4 ]
then
echo "testProcessBlock4"
- cmsRun -p ${LOCAL_TEST_DIR}/testProcessBlock4_cfg.py &> testProcessBlock4.log || die "cmsRun testProcessBlock4_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/testProcessBlock4_cfg.py &> testProcessBlock4.log || die "cmsRun testProcessBlock4_cfg.py" $?
fi
if [ $1 -eq 5 ]
then
echo "testProcessBlockMerge"
- cmsRun -p ${LOCAL_TEST_DIR}/testProcessBlockMerge_cfg.py &> testProcessBlockMerge.log || die "cmsRun testProcessBlockMerge_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/testProcessBlockMerge_cfg.py &> testProcessBlockMerge.log || die "cmsRun testProcessBlockMerge_cfg.py" $?
# The ProcessBlock Branches and TTrees should exist in this case. Test that here:
edmFileUtil -l -t MetaData -P file:testProcessBlockMerge.root > testProcessBlockMContentsM.txt
@@ -68,10 +68,10 @@ fi
if [ $1 -eq 6 ]
then
echo "testProcessBlockTEST"
- cmsRun -p ${LOCAL_TEST_DIR}/testProcessBlockTEST_cfg.py &> testProcessBlockTEST.log || die "cmsRun testProcessBlockTEST_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/testProcessBlockTEST_cfg.py &> testProcessBlockTEST.log || die "cmsRun testProcessBlockTEST_cfg.py" $?
echo "testProcessBlockRead"
- cmsRun -p ${LOCAL_TEST_DIR}/testProcessBlockRead_cfg.py &> testProcessBlockRead.log || die "cmsRun testProcessBlockRead_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/testProcessBlockRead_cfg.py &> testProcessBlockRead.log || die "cmsRun testProcessBlockRead_cfg.py" $?
grep "InputProcessBlockIntAnalyzer::accessInputProcessBlock" testProcessBlockRead.log || die "Check that InputProcessBlockIntAnalyzer::accessInputProcessBlock was called" $?
grep "InputProcessBlockIntFilter::accessInputProcessBlock" testProcessBlockRead.log || die "Check that InputProcessBlockIntFilter::accessInputProcessBlock was called" $?
grep "InputProcessBlockIntProducer::accessInputProcessBlock" testProcessBlockRead.log || die "Check that InputProcessBlockIntProducer::accessInputProcessBlock was called" $?
@@ -80,7 +80,7 @@ fi
if [ $1 -eq 7 ]
then
echo "testProcessBlock2Dropped"
- cmsRun -p ${LOCAL_TEST_DIR}/testProcessBlock2Dropped_cfg.py &> testProcessBlock2Dropped.log || die "cmsRun testProcessBlock2Dropped_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/testProcessBlock2Dropped_cfg.py &> testProcessBlock2Dropped.log || die "cmsRun testProcessBlock2Dropped_cfg.py" $?
# The ProcessBlock Branches and TTrees should not exist in this case because
# all the ProcessBlock products are dropped. Test that here:
@@ -96,112 +96,112 @@ then
# This one intentionally fails because the product content of the
# files does not match (strict merging requirements for ProcessBlocks)
echo "testProcessBlockFailMerge"
- cmsRun -p ${LOCAL_TEST_DIR}/testProcessBlockFailMerge_cfg.py &> testProcessBlockFailMerge.log && die "cmsRun testProcessBlockFailMerge_cfg.py" 1
+ cmsRun ${LOCAL_TEST_DIR}/testProcessBlockFailMerge_cfg.py &> testProcessBlockFailMerge.log && die "cmsRun testProcessBlockFailMerge_cfg.py" 1
fi
if [ $1 -eq 9 ]
then
echo "testProcessBlockMerge2"
- cmsRun -p ${LOCAL_TEST_DIR}/testProcessBlockMerge2_cfg.py &> testProcessBlockMerge2.log || die "cmsRun testProcessBlockMerge2_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/testProcessBlockMerge2_cfg.py &> testProcessBlockMerge2.log || die "cmsRun testProcessBlockMerge2_cfg.py" $?
fi
if [ $1 -eq 10 ]
then
echo "testProcessBlockMergeOfMergedFiles"
- cmsRun -p ${LOCAL_TEST_DIR}/testProcessBlockMergeOfMergedFiles_cfg.py &> testProcessBlockMergeOfMergedFiles.log || die "cmsRun testProcessBlockMergeOfMergedFiles_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/testProcessBlockMergeOfMergedFiles_cfg.py &> testProcessBlockMergeOfMergedFiles.log || die "cmsRun testProcessBlockMergeOfMergedFiles_cfg.py" $?
fi
if [ $1 -eq 11 ]
then
echo "testProcessBlockNOMergeOfMergedFiles"
- cmsRun -p ${LOCAL_TEST_DIR}/testProcessBlockNOMergeOfMergedFiles_cfg.py &> testProcessBlockNOMergeOfMergedFiles.log || die "cmsRun testProcessBlockNOMergeOfMergedFiles_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/testProcessBlockNOMergeOfMergedFiles_cfg.py &> testProcessBlockNOMergeOfMergedFiles.log || die "cmsRun testProcessBlockNOMergeOfMergedFiles_cfg.py" $?
fi
if [ $1 -eq 12 ]
then
echo "testProcessBlockRead2"
- cmsRun -p ${LOCAL_TEST_DIR}/testProcessBlockRead2_cfg.py &> testProcessBlockRead2.log || die "cmsRun testProcessBlockRead2_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/testProcessBlockRead2_cfg.py &> testProcessBlockRead2.log || die "cmsRun testProcessBlockRead2_cfg.py" $?
fi
if [ $1 -eq 14 ]
then
echo "testProcessBlockSubProcess"
- cmsRun -p ${LOCAL_TEST_DIR}/testProcessBlockSubProcess_cfg.py &> testProcessBlockSubProcess.log || die "cmsRun testProcessBlockSubProcess_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/testProcessBlockSubProcess_cfg.py &> testProcessBlockSubProcess.log || die "cmsRun testProcessBlockSubProcess_cfg.py" $?
fi
if [ $1 -eq 15 ]
then
echo "testProcessBlockSubProcessRead1"
- cmsRun -p ${LOCAL_TEST_DIR}/testProcessBlockSubProcessRead1_cfg.py &> testProcessBlockSubProcessRead1.log || die "cmsRun testProcessBlockSubProcessRead1_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/testProcessBlockSubProcessRead1_cfg.py &> testProcessBlockSubProcessRead1.log || die "cmsRun testProcessBlockSubProcessRead1_cfg.py" $?
fi
if [ $1 -eq 16 ]
then
echo "testProcessBlockSubProcessRead2"
- cmsRun -p ${LOCAL_TEST_DIR}/testProcessBlockSubProcessRead2_cfg.py &> testProcessBlockSubProcessRead2.log || die "cmsRun testProcessBlockSubProcessRead2_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/testProcessBlockSubProcessRead2_cfg.py &> testProcessBlockSubProcessRead2.log || die "cmsRun testProcessBlockSubProcessRead2_cfg.py" $?
fi
if [ $1 -eq 17 ]
then
echo "testProcessBlockSubProcessLooper"
- cmsRun -p ${LOCAL_TEST_DIR}/testProcessBlockSubProcessLooper_cfg.py &> testProcessBlockSubProcessLooper.log || die "cmsRun testProcessBlockSubProcessLooper_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/testProcessBlockSubProcessLooper_cfg.py &> testProcessBlockSubProcessLooper.log || die "cmsRun testProcessBlockSubProcessLooper_cfg.py" $?
fi
if [ $1 -eq 18 ]
then
echo "testProcessBlock5"
- cmsRun -p ${LOCAL_TEST_DIR}/testProcessBlock5_cfg.py &> testProcessBlock5.log || die "cmsRun testProcessBlock5_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/testProcessBlock5_cfg.py &> testProcessBlock5.log || die "cmsRun testProcessBlock5_cfg.py" $?
echo "testProcessBlockMerge3"
- cmsRun -p ${LOCAL_TEST_DIR}/testProcessBlockMerge3_cfg.py &> testProcessBlockMerge3.log || die "cmsRun testProcessBlockMerge3_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/testProcessBlockMerge3_cfg.py &> testProcessBlockMerge3.log || die "cmsRun testProcessBlockMerge3_cfg.py" $?
echo "testProcessBlockMergeOfMergedFiles2"
- cmsRun -p ${LOCAL_TEST_DIR}/testProcessBlockMergeOfMergedFiles2_cfg.py &> testProcessBlockMergeOfMergedFiles2.log || die "cmsRun testProcessBlockMergeOfMergedFiles2_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/testProcessBlockMergeOfMergedFiles2_cfg.py &> testProcessBlockMergeOfMergedFiles2.log || die "cmsRun testProcessBlockMergeOfMergedFiles2_cfg.py" $?
fi
if [ $1 -eq 19 ]
then
echo "testProcessBlockDropOnInput"
- cmsRun -p ${LOCAL_TEST_DIR}/testProcessBlockDropOnInput_cfg.py &> testProcessBlockDropOnInput.log || die "cmsRun testProcessBlockDropOnInput_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/testProcessBlockDropOnInput_cfg.py &> testProcessBlockDropOnInput.log || die "cmsRun testProcessBlockDropOnInput_cfg.py" $?
fi
if [ $1 -eq 20 ]
then
echo "testProcessBlockThreeFileInput"
- cmsRun -p ${LOCAL_TEST_DIR}/testProcessBlockThreeFileInput_cfg.py &> testProcessBlockThreeFileInput.log || die "cmsRun testProcessBlockThreeFileInput_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/testProcessBlockThreeFileInput_cfg.py &> testProcessBlockThreeFileInput.log || die "cmsRun testProcessBlockThreeFileInput_cfg.py" $?
echo "testProcessBlockReadThreeFileInput"
- cmsRun -p ${LOCAL_TEST_DIR}/testProcessBlockReadThreeFileInput_cfg.py &> testProcessBlockReadThreeFileInput.log || die "cmsRun testProcessBlockReadThreeFileInput_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/testProcessBlockReadThreeFileInput_cfg.py &> testProcessBlockReadThreeFileInput.log || die "cmsRun testProcessBlockReadThreeFileInput_cfg.py" $?
fi
if [ $1 -eq 21 ]
then
echo "testLooperEventNavigation2"
- cmsRun -p ${LOCAL_TEST_DIR}/testLooperEventNavigation2_cfg.py < ${LOCAL_TEST_DIR}/testLooperEventNavigation2.txt &> testLooperEventNavigation2.log || die "cmsRun testLooperEventNavigation2_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/testLooperEventNavigation2_cfg.py < ${LOCAL_TEST_DIR}/testLooperEventNavigation2.txt &> testLooperEventNavigation2.log || die "cmsRun testLooperEventNavigation2_cfg.py" $?
fi
if [ $1 -eq 22 ]
then
echo "testLooperEventNavigation3"
- cmsRun -p ${LOCAL_TEST_DIR}/testLooperEventNavigation3_cfg.py < ${LOCAL_TEST_DIR}/testLooperEventNavigation3.txt &> testLooperEventNavigation3.log || die "cmsRun testLooperEventNavigation3_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/testLooperEventNavigation3_cfg.py < ${LOCAL_TEST_DIR}/testLooperEventNavigation3.txt &> testLooperEventNavigation3.log || die "cmsRun testLooperEventNavigation3_cfg.py" $?
fi
if [ $1 -eq 23 ]
then
echo "testProcessBlockDropOnOutput"
- cmsRun -p ${LOCAL_TEST_DIR}/testProcessBlockDropOnOutput_cfg.py &> testProcessBlockDropOnOutput.log || die "cmsRun testProcessBlockDropOnOutput_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/testProcessBlockDropOnOutput_cfg.py &> testProcessBlockDropOnOutput.log || die "cmsRun testProcessBlockDropOnOutput_cfg.py" $?
echo "testProcessBlockReadDropOnOutput"
- cmsRun -p ${LOCAL_TEST_DIR}/testProcessBlockReadDropOnOutput_cfg.py &> testProcessBlockReadDropOnOutput.log || die "cmsRun testProcessBlockReadDropOnOutput_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/testProcessBlockReadDropOnOutput_cfg.py &> testProcessBlockReadDropOnOutput.log || die "cmsRun testProcessBlockReadDropOnOutput_cfg.py" $?
fi
if [ $1 -eq 24 ]
then
echo "testProcessBlockDropOnOutput2"
- cmsRun -p ${LOCAL_TEST_DIR}/testProcessBlockDropOnOutput2_cfg.py &> testProcessBlockDropOnOutput2.log || die "cmsRun testProcessBlockDropOnOutput2_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/testProcessBlockDropOnOutput2_cfg.py &> testProcessBlockDropOnOutput2.log || die "cmsRun testProcessBlockDropOnOutput2_cfg.py" $?
echo "testProcessBlockReadDropOnOutput2"
- cmsRun -p ${LOCAL_TEST_DIR}/testProcessBlockReadDropOnOutput2_cfg.py &> testProcessBlockReadDropOnOutput2.log || die "cmsRun testProcessBlockReadDropOnOutput2_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/testProcessBlockReadDropOnOutput2_cfg.py &> testProcessBlockReadDropOnOutput2.log || die "cmsRun testProcessBlockReadDropOnOutput2_cfg.py" $?
fi
# The next three tests would be relevant if we disabled the strict merging requirement
@@ -216,16 +216,16 @@ fi
#if [ $1 -eq 25 ]
#then
# echo "testProcessBlockNonStrict"
-# cmsRun -p ${LOCAL_TEST_DIR}/testProcessBlockNonStrict_cfg.py &> testProcessBlockNonStrict.log || die "cmsRun testProcessBlockNonStrict_cfg.py" $?
+# cmsRun ${LOCAL_TEST_DIR}/testProcessBlockNonStrict_cfg.py &> testProcessBlockNonStrict.log || die "cmsRun testProcessBlockNonStrict_cfg.py" $?
#
# echo "testProcessBlockNonStrict2"
-# cmsRun -p ${LOCAL_TEST_DIR}/testProcessBlockNonStrict2_cfg.py &> testProcessBlockNonStrict2.log || die "cmsRun testProcessBlockNonStrict2_cfg.py" $?
+# cmsRun ${LOCAL_TEST_DIR}/testProcessBlockNonStrict2_cfg.py &> testProcessBlockNonStrict2.log || die "cmsRun testProcessBlockNonStrict2_cfg.py" $?
#fi
#if [ $1 -eq 26 ]
#then
# echo "testProcessBlockNonStrict3"
-# cmsRun -p ${LOCAL_TEST_DIR}/testProcessBlockNonStrict3_cfg.py &> testProcessBlockNonStrict3.log || die "cmsRun testProcessBlockNonStrict3_cfg.py" $?
+# cmsRun ${LOCAL_TEST_DIR}/testProcessBlockNonStrict3_cfg.py &> testProcessBlockNonStrict3.log || die "cmsRun testProcessBlockNonStrict3_cfg.py" $?
#fi
if [ $1 -eq 100 ]
diff --git a/FWCore/Integration/test/run_TestSwitchProducer.sh b/FWCore/Integration/test/run_TestSwitchProducer.sh
index 26b25c79e589c..981c5e745058f 100755
--- a/FWCore/Integration/test/run_TestSwitchProducer.sh
+++ b/FWCore/Integration/test/run_TestSwitchProducer.sh
@@ -15,15 +15,15 @@ LOCAL_TEST_DIR=${SCRAM_TEST_PATH}
echo "*************************************************"
echo "SwitchProducer in a Task, case test2 disabled"
- cmsRun -n ${NUMTHREADS} ${LOCAL_TEST_DIR}/${test}Task_cfg.py -- --disableTest2 || die "cmsRun ${test}Task_cfg.py -- --disableTest2" $?
+ cmsRun -n ${NUMTHREADS} ${LOCAL_TEST_DIR}/${test}Task_cfg.py --disableTest2 || die "cmsRun ${test}Task_cfg.py --disableTest2" $?
echo "*************************************************"
echo "SwitchProducer in a Task, SwitchProducers have same labels as products in input file"
- cmsRun -n ${NUMTHREADS} ${LOCAL_TEST_DIR}/${test}Task_cfg.py -- --input|| die "cmsRun ${test}Task_cfg.py -- --input" $?
+ cmsRun -n ${NUMTHREADS} ${LOCAL_TEST_DIR}/${test}Task_cfg.py --input|| die "cmsRun ${test}Task_cfg.py --input" $?
echo "*************************************************"
echo "SwitchProducer in a Task, SwitchProducers have same labels as products in input file, case test2 disabled"
- cmsRun -n ${NUMTHREADS} ${LOCAL_TEST_DIR}/${test}Task_cfg.py -- --input --disableTest2 || die "cmsRun ${test}TaskInput_cfg.py -- --input --disableTest2" $?
+ cmsRun -n ${NUMTHREADS} ${LOCAL_TEST_DIR}/${test}Task_cfg.py --input --disableTest2 || die "cmsRun ${test}TaskInput_cfg.py --input --disableTest2" $?
echo "*************************************************"
echo "Merge outputs (Task)"
@@ -42,11 +42,11 @@ LOCAL_TEST_DIR=${SCRAM_TEST_PATH}
echo "*************************************************"
echo "SwitchProducer in a ConditionalTask"
- cmsRun -n ${NUMTHREADS} ${LOCAL_TEST_DIR}/${test}Task_cfg.py -- --conditionalTask || die "cmsRun ${test}Task_cfg.py -- --conditionalTask" $?
+ cmsRun -n ${NUMTHREADS} ${LOCAL_TEST_DIR}/${test}Task_cfg.py --conditionalTask || die "cmsRun ${test}Task_cfg.py --conditionalTask" $?
echo "*************************************************"
echo "SwitchProducer in a ConditionalTask, case test2 disabled"
- cmsRun -n ${NUMTHREADS} ${LOCAL_TEST_DIR}/${test}Task_cfg.py -- --conditionalTask --disableTest2 || die "cmsRun ${test}Task_cfg.py -- --conditionalTask --disableTest2" $?
+ cmsRun -n ${NUMTHREADS} ${LOCAL_TEST_DIR}/${test}Task_cfg.py --conditionalTask --disableTest2 || die "cmsRun ${test}Task_cfg.py --conditionalTask --disableTest2" $?
echo "*************************************************"
echo "Merge outputs (ConditionalTask)"
@@ -84,11 +84,11 @@ LOCAL_TEST_DIR=${SCRAM_TEST_PATH}
echo "*************************************************"
echo "SwitchProducer in a ConditionalTask, test EDAlias with a wildcard pattern, other module having the wildcard"
- cmsRun -n ${NUMTHREADS} ${LOCAL_TEST_DIR}/${test}ConditionalTaskEDAliasWildcard_cfg.py -- --patternOnOtherModule || die "cmsRun ${test}ConditionalTaskEDAliasWildcard_cfg.py --patternOnOtherModule" $?
+ cmsRun -n ${NUMTHREADS} ${LOCAL_TEST_DIR}/${test}ConditionalTaskEDAliasWildcard_cfg.py --wildcardOnOtherModule || die "cmsRun ${test}ConditionalTaskEDAliasWildcard_cfg.py --wildcardOnOtherModule" $?
echo "*************************************************"
echo "SwitchProducer in a ConditionalTask, test EDAlias with an a wildcard, case test2 disabled"
- cmsRun -n ${NUMTHREADS} ${LOCAL_TEST_DIR}/${test}ConditionalTaskEDAliasWildcard_cfg.py -- --disableTest2 || die "cmsRun ${test}ConditionalTaskEDAliasWildcard_cfg.py --disableTest2" $?
+ cmsRun -n ${NUMTHREADS} ${LOCAL_TEST_DIR}/${test}ConditionalTaskEDAliasWildcard_cfg.py --disableTest2 || die "cmsRun ${test}ConditionalTaskEDAliasWildcard_cfg.py --disableTest2" $?
diff --git a/FWCore/Integration/test/run_ThinningTests.sh b/FWCore/Integration/test/run_ThinningTests.sh
index 03984d1c39504..24bf1835dcde9 100755
--- a/FWCore/Integration/test/run_ThinningTests.sh
+++ b/FWCore/Integration/test/run_ThinningTests.sh
@@ -4,51 +4,51 @@ function die { echo Failure $1: status $2 ; exit $2 ; }
LOCAL_TEST_DIR=${SCRAM_TEST_PATH}
- cmsRun -p ${LOCAL_TEST_DIR}/ThinningTest1_cfg.py || die "cmsRun ThinningTest1_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/ThinningTest1_cfg.py || die "cmsRun ThinningTest1_cfg.py" $?
- cmsRun -p ${LOCAL_TEST_DIR}/ThinningTest2_cfg.py || die "cmsRun ThinningTest2_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/ThinningTest2_cfg.py || die "cmsRun ThinningTest2_cfg.py" $?
- cmsRun -p ${LOCAL_TEST_DIR}/ThinningTest3_cfg.py || die "cmsRun ThinningTest3_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/ThinningTest3_cfg.py || die "cmsRun ThinningTest3_cfg.py" $?
- cmsRun -p ${LOCAL_TEST_DIR}/ThinningTest4_cfg.py || die "cmsRun ThinningTest4_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/ThinningTest4_cfg.py || die "cmsRun ThinningTest4_cfg.py" $?
- cmsRun -p ${LOCAL_TEST_DIR}/ThinningTest_dropOnInput_cfg.py || die "cmsRun ThinningTest_dropOnInput_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/ThinningTest_dropOnInput_cfg.py || die "cmsRun ThinningTest_dropOnInput_cfg.py" $?
- cmsRun -p ${LOCAL_TEST_DIR}/ThinningTestSubProcess_cfg.py || die "cmsRun ThinningTestSubProcess_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/ThinningTestSubProcess_cfg.py || die "cmsRun ThinningTestSubProcess_cfg.py" $?
- cmsRun -p ${LOCAL_TEST_DIR}/ThinningTestSubProcessRead_cfg.py || die "cmsRun ThinningTestSubProcessRead_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/ThinningTestSubProcessRead_cfg.py || die "cmsRun ThinningTestSubProcessRead_cfg.py" $?
- cmsRun -p ${LOCAL_TEST_DIR}/ThinningTestStreamerIn_cfg.py || die "cmsRun ThinningTestStreamerIn_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/ThinningTestStreamerIn_cfg.py || die "cmsRun ThinningTestStreamerIn_cfg.py" $?
- cmsRun -p ${LOCAL_TEST_DIR}/ThinningTest4Slimming_cfg.py || die "cmsRun ThinningTest4Slimming_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/ThinningTest4Slimming_cfg.py || die "cmsRun ThinningTest4Slimming_cfg.py" $?
- cmsRun -p ${LOCAL_TEST_DIR}/DetSetVectorThinningTest1_cfg.py || die "cmsRun DetSetVectorThinningTest1_cfg.py" $?
- cmsRun -p ${LOCAL_TEST_DIR}/DetSetVectorThinningTest2_cfg.py || die "cmsRun DetSetVectorThinningTest2_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/DetSetVectorThinningTest1_cfg.py || die "cmsRun DetSetVectorThinningTest1_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/DetSetVectorThinningTest2_cfg.py || die "cmsRun DetSetVectorThinningTest2_cfg.py" $?
- cmsRun -p ${LOCAL_TEST_DIR}/SlimmingTestSiblings_cfg.py && die "cmsRun SlimmingTestSiblings_cfg.py"1
+ cmsRun ${LOCAL_TEST_DIR}/SlimmingTestSiblings_cfg.py && die "cmsRun SlimmingTestSiblings_cfg.py"1
- cmsRun -p ${LOCAL_TEST_DIR}/SlimmingTestFartherSiblings_cfg.py && die "cmsRun SlimmingTestFartherSiblings_cfg.py" 1
+ cmsRun ${LOCAL_TEST_DIR}/SlimmingTestFartherSiblings_cfg.py && die "cmsRun SlimmingTestFartherSiblings_cfg.py" 1
- cmsRun -p ${LOCAL_TEST_DIR}/SlimmingTest1_cfg.py || die "cmsRun SlimmingTest1_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/SlimmingTest1_cfg.py || die "cmsRun SlimmingTest1_cfg.py" $?
- cmsRun -p ${LOCAL_TEST_DIR}/SlimmingTest2A_cfg.py || die "cmsRun SlimmingTest2A_cfg.py" $?
- cmsRun -p ${LOCAL_TEST_DIR}/SlimmingTest2B_cfg.py || die "cmsRun SlimmingTest2B_cfg.py" $?
- cmsRun -p ${LOCAL_TEST_DIR}/SlimmingTest2C_cfg.py || die "cmsRun SlimmingTest2C_cfg.py" $?
- cmsRun -p ${LOCAL_TEST_DIR}/SlimmingTest2D_cfg.py || die "cmsRun SlimmingTest2D_cfg.py" $?
- cmsRun -p ${LOCAL_TEST_DIR}/SlimmingTest2E_cfg.py || die "cmsRun SlimmingTest2E_cfg.py" $?
- cmsRun -p ${LOCAL_TEST_DIR}/SlimmingTest2F_cfg.py || die "cmsRun SlimmingTest2E_cfg.py" $?
- cmsRun -p ${LOCAL_TEST_DIR}/SlimmingTest2G_cfg.py || die "cmsRun SlimmingTest2G_cfg.py" $?
- cmsRun -p ${LOCAL_TEST_DIR}/SlimmingTest2H_cfg.py || die "cmsRun SlimmingTest2H_cfg.py" $?
- cmsRun -p ${LOCAL_TEST_DIR}/SlimmingTest2I_cfg.py || die "cmsRun SlimmingTest2I_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/SlimmingTest2A_cfg.py || die "cmsRun SlimmingTest2A_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/SlimmingTest2B_cfg.py || die "cmsRun SlimmingTest2B_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/SlimmingTest2C_cfg.py || die "cmsRun SlimmingTest2C_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/SlimmingTest2D_cfg.py || die "cmsRun SlimmingTest2D_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/SlimmingTest2E_cfg.py || die "cmsRun SlimmingTest2E_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/SlimmingTest2F_cfg.py || die "cmsRun SlimmingTest2E_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/SlimmingTest2G_cfg.py || die "cmsRun SlimmingTest2G_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/SlimmingTest2H_cfg.py || die "cmsRun SlimmingTest2H_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/SlimmingTest2I_cfg.py || die "cmsRun SlimmingTest2I_cfg.py" $?
- cmsRun -p ${LOCAL_TEST_DIR}/SlimmingTest3B_cfg.py || die "cmsRun SlimmingTest3B_cfg.py" $?
- cmsRun -p ${LOCAL_TEST_DIR}/SlimmingTest3C_cfg.py || die "cmsRun SlimmingTest3C_cfg.py" $?
- cmsRun -p ${LOCAL_TEST_DIR}/SlimmingTest3D_cfg.py || die "cmsRun SlimmingTest3D_cfg.py" $?
- cmsRun -p ${LOCAL_TEST_DIR}/SlimmingTest3E_cfg.py || die "cmsRun SlimmingTest3E_cfg.py" $?
- cmsRun -p ${LOCAL_TEST_DIR}/SlimmingTest3F_cfg.py || die "cmsRun SlimmingTest3F_cfg.py" $?
- cmsRun -p ${LOCAL_TEST_DIR}/SlimmingTest3I_cfg.py || die "cmsRun SlimmingTest3I_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/SlimmingTest3B_cfg.py || die "cmsRun SlimmingTest3B_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/SlimmingTest3C_cfg.py || die "cmsRun SlimmingTest3C_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/SlimmingTest3D_cfg.py || die "cmsRun SlimmingTest3D_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/SlimmingTest3E_cfg.py || die "cmsRun SlimmingTest3E_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/SlimmingTest3F_cfg.py || die "cmsRun SlimmingTest3F_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/SlimmingTest3I_cfg.py || die "cmsRun SlimmingTest3I_cfg.py" $?
- cmsRun -p ${LOCAL_TEST_DIR}/SlimmingTest4B_cfg.py || die "cmsRun SlimmingTest4B_cfg.py" $?
- cmsRun -p ${LOCAL_TEST_DIR}/SlimmingTest4F_cfg.py && die "cmsRun SlimmingTest4F_cfg.py" 1
+ cmsRun ${LOCAL_TEST_DIR}/SlimmingTest4B_cfg.py || die "cmsRun SlimmingTest4B_cfg.py" $?
+ cmsRun ${LOCAL_TEST_DIR}/SlimmingTest4F_cfg.py && die "cmsRun SlimmingTest4F_cfg.py" 1
exit 0
diff --git a/FWCore/Integration/test/run_unscheduledFailOnOutput.sh b/FWCore/Integration/test/run_unscheduledFailOnOutput.sh
index 8212b01de03be..9c52874f9113a 100755
--- a/FWCore/Integration/test/run_unscheduledFailOnOutput.sh
+++ b/FWCore/Integration/test/run_unscheduledFailOnOutput.sh
@@ -11,10 +11,10 @@ function die { echo Failure $1: status $2 ; exit $2 ; }
cmsRun ${CFG_DIR}/${test}IgnoreCompletely_cfg.py || die "cmsRun ${test}IgnoreCompletely_cfg.py" $?
cmsRun ${CFG_DIR}/${test}read_found_events.py || die "cmsRun ${test}read_found_events.py for IgnoreCompletely" $?
- cmsRun -p ${CFG_DIR}/${test}TryToContinue_cfg.py || die "cmsRun ${test}TryToComplete_cfg.py" $?
+ cmsRun ${CFG_DIR}/${test}TryToContinue_cfg.py || die "cmsRun ${test}TryToComplete_cfg.py" $?
cmsRun ${CFG_DIR}/${test}read_no_events.py || die "cmsRun ${test}read_no_events.py" $?
- cmsRun -p ${CFG_DIR}/${test}no_dependency_TryToContinue_cfg.py || die "cmsRun ${test}no_dependency_TryToComplete_cfg.py" $?
+ cmsRun ${CFG_DIR}/${test}no_dependency_TryToContinue_cfg.py || die "cmsRun ${test}no_dependency_TryToComplete_cfg.py" $?
cmsRun ${CFG_DIR}/${test}read_found_events.py || die "cmsRun ${test}read_found_events.py for TryToComplete" $?
exit 0
diff --git a/FWCore/Integration/test/service_example.sh b/FWCore/Integration/test/service_example.sh
index 6207e9761805e..4d56c71ce6e33 100755
--- a/FWCore/Integration/test/service_example.sh
+++ b/FWCore/Integration/test/service_example.sh
@@ -2,4 +2,4 @@
function die { echo $1: status $2 ; exit $2; }
-cmsRun --parameter-set ${SCRAM_TEST_PATH}/service_example_cfg.py || die 'Failed in service_example_cfg.py' $?
+cmsRun ${SCRAM_TEST_PATH}/service_example_cfg.py || die 'Failed in service_example_cfg.py' $?
diff --git a/FWCore/Integration/test/testGetByLabelStep2_cfg.py b/FWCore/Integration/test/testGetByLabelStep2_cfg.py
index 69c058864a9b5..23d22815746c0 100644
--- a/FWCore/Integration/test/testGetByLabelStep2_cfg.py
+++ b/FWCore/Integration/test/testGetByLabelStep2_cfg.py
@@ -9,10 +9,7 @@
parser.add_argument("--thing", help="Add producer and consumer for Thing", action="store_true")
parser.add_argument("--otherInt", help="Add another producer and consumer for int", action="store_true")
-argv = sys.argv[:]
-if '--' in argv:
- argv.remove("--")
-args, unknown = parser.parse_known_args(argv)
+args = parser.parse_args()
process = cms.Process("TESTANA")
process.maxEvents.input = -1
diff --git a/FWCore/Integration/test/testModuleTypeResolver_cfg.py b/FWCore/Integration/test/testModuleTypeResolver_cfg.py
index a457ee1b8c0f3..ca41292f5919e 100644
--- a/FWCore/Integration/test/testModuleTypeResolver_cfg.py
+++ b/FWCore/Integration/test/testModuleTypeResolver_cfg.py
@@ -11,10 +11,7 @@
parser.add_argument("--accelerators", type=str, help="Comma-separated string for accelerators to enable")
parser.add_argument("--expectOther", action="store_true", help="Set this if the 'other' variant is expected to get run")
-argv = sys.argv[:]
-if '--' in argv:
- argv.remove("--")
-args, unknown = parser.parse_known_args(argv)
+args = parser.parse_args()
class ModuleTypeResolverTest:
def __init__(self, accelerators):
diff --git a/FWCore/Integration/test/testProcessAccelerator_cfg.py b/FWCore/Integration/test/testProcessAccelerator_cfg.py
index b5f8b95694b1a..2619c1f4be5cf 100644
--- a/FWCore/Integration/test/testProcessAccelerator_cfg.py
+++ b/FWCore/Integration/test/testProcessAccelerator_cfg.py
@@ -8,10 +8,7 @@
parser.add_argument("--enableTest2", help="Enable test2 accelerator", action="store_true")
parser.add_argument("--accelerators", type=str, help="Comma-separated string for accelerators to enable")
-argv = sys.argv[:]
-if '--' in argv:
- argv.remove("--")
-args, unknown = parser.parse_known_args(argv)
+args = parser.parse_args()
class ProcessAcceleratorTest(cms.ProcessAccelerator):
def __init__(self):
diff --git a/FWCore/Integration/test/testSwitchProducerConditionalTaskEDAliasWildcard_cfg.py b/FWCore/Integration/test/testSwitchProducerConditionalTaskEDAliasWildcard_cfg.py
index df4665c623edb..66fc5478e4f1a 100644
--- a/FWCore/Integration/test/testSwitchProducerConditionalTaskEDAliasWildcard_cfg.py
+++ b/FWCore/Integration/test/testSwitchProducerConditionalTaskEDAliasWildcard_cfg.py
@@ -7,10 +7,7 @@
parser.add_argument("--disableTest2", help="Disable 'test2' case of the SwitchProducerTest", action="store_true")
parser.add_argument("--wildcardOnOtherModule", help="Use the wildcard for alias from another module", action="store_true")
-argv = sys.argv[:]
-if '--' in argv:
- argv.remove("--")
-args, unknown = parser.parse_known_args(argv)
+args = parser.parse_args()
enableTest2 = not args.disableTest2
class SwitchProducerTest(cms.SwitchProducer):
diff --git a/FWCore/Integration/test/testSwitchProducerTask_cfg.py b/FWCore/Integration/test/testSwitchProducerTask_cfg.py
index 83ff028752ef4..f92aa69dc16f7 100644
--- a/FWCore/Integration/test/testSwitchProducerTask_cfg.py
+++ b/FWCore/Integration/test/testSwitchProducerTask_cfg.py
@@ -8,10 +8,7 @@
parser.add_argument("--input", help="Read input file from a previous step of this same configuration", action="store_true")
parser.add_argument("--conditionalTask", help="Use ConditionalTask instead of Task", action="store_true")
-argv = sys.argv[:]
-if '--' in argv:
- argv.remove("--")
-args, unknown = parser.parse_known_args(argv)
+args = parser.parse_args()
enableTest2 = not args.disableTest2
class SwitchProducerTest(cms.SwitchProducer):
diff --git a/FWCore/Integration/test/test_TryToContinue_ESProducer_cfg.py b/FWCore/Integration/test/test_TryToContinue_ESProducer_cfg.py
index 1522bea740660..6c22ab17625d2 100644
--- a/FWCore/Integration/test/test_TryToContinue_ESProducer_cfg.py
+++ b/FWCore/Integration/test/test_TryToContinue_ESProducer_cfg.py
@@ -7,10 +7,7 @@
parser.add_argument("--continueAnalyzer", help="Apply shouldTryToContinue to module dependent on module that fails.", action="store_true")
-argv = sys.argv[:]
-if '--' in argv:
- argv.remove("--")
-args, unknown = parser.parse_known_args(argv)
+args = parser.parse_args()
process = cms.Process("Demo")
diff --git a/FWCore/Integration/test/test_TryToContinue_cfg.py b/FWCore/Integration/test/test_TryToContinue_cfg.py
index 3ea6fbc27918f..6d6781c556c38 100644
--- a/FWCore/Integration/test/test_TryToContinue_cfg.py
+++ b/FWCore/Integration/test/test_TryToContinue_cfg.py
@@ -9,10 +9,7 @@
parser.add_argument("--inRun", help="throw exception in begin run", action="store_true")
parser.add_argument("--inLumi", help="throw exception in begin lumi", action="store_true")
-argv = sys.argv[:]
-if '--' in argv:
- argv.remove("--")
-args, unknown = parser.parse_known_args(argv)
+args = parser.parse_args()
process = cms.Process("TEST")
diff --git a/FWCore/Integration/test/test_finalpath.sh b/FWCore/Integration/test/test_finalpath.sh
index 6e002d69b51ec..2b3c9dd1b7c22 100755
--- a/FWCore/Integration/test/test_finalpath.sh
+++ b/FWCore/Integration/test/test_finalpath.sh
@@ -12,7 +12,7 @@ cmsRun ${LOCAL_TEST_DIR}/test_finalpath_cfg.py >& finalpath.log || die "failed
grep "thing '.*' TEST" finalpath.log | diff finalpath_expected_empty.log - || die "differences for test_finalpath_cfg.py" $?
-cmsRun ${LOCAL_TEST_DIR}/test_finalpath_cfg.py -- --schedule >& finalpath.log || die "failed test_finalpath_cfg.py --schedule" $?
+cmsRun ${LOCAL_TEST_DIR}/test_finalpath_cfg.py --schedule >& finalpath.log || die "failed test_finalpath_cfg.py --schedule" $?
grep "thing '.*' TEST" finalpath.log | diff finalpath_expected_empty.log - || die "differences for test_finalpath_cfg.py" $?
@@ -25,14 +25,14 @@ found thing 'endLumi' TEST
found thing 'beginRun' TEST
found thing 'endRun' TEST
EOF
-cmsRun ${LOCAL_TEST_DIR}/test_finalpath_cfg.py -- --schedule --task >& finalpath.log || die "failed test_finalpath_cfg.py --schedule --task" $?
+cmsRun ${LOCAL_TEST_DIR}/test_finalpath_cfg.py --schedule --task >& finalpath.log || die "failed test_finalpath_cfg.py --schedule --task" $?
grep "thing '.*' TEST" finalpath.log | diff finalpath_expected_not_found.log - || die "differences for test_finalpath_cfg.py --schedule --task" $?
-cmsRun ${LOCAL_TEST_DIR}/test_finalpath_cfg.py -- --endpath >& finalpath.log || die "failed test_finalpath_cfg.py --endpath" $?
+cmsRun ${LOCAL_TEST_DIR}/test_finalpath_cfg.py --endpath >& finalpath.log || die "failed test_finalpath_cfg.py --endpath" $?
grep "thing '.*' TEST" finalpath.log | diff finalpath_expected_empty.log - || die "differences for test_finalpath_cfg.py --endpath" $?
-cmsRun ${LOCAL_TEST_DIR}/test_finalpath_cfg.py -- --schedule --endpath >& finalpath.log || die "failed test_finalpath_cfg.py --schedule --endpath" $?
+cmsRun ${LOCAL_TEST_DIR}/test_finalpath_cfg.py --schedule --endpath >& finalpath.log || die "failed test_finalpath_cfg.py --schedule --endpath" $?
grep "thing '.*' TEST" finalpath.log | diff finalpath_expected_empty.log - || die "differences for test_finalpath_cfg.py --schedule --endpath" $?
@@ -45,16 +45,16 @@ found thing 'endLumi' TEST
found thing 'beginRun' TEST
found thing 'endRun' TEST
EOF
-cmsRun ${LOCAL_TEST_DIR}/test_finalpath_cfg.py -- --endpath --task >& finalpath.log || die "failed test_finalpath_cfg.py --endpath --task" $?
+cmsRun ${LOCAL_TEST_DIR}/test_finalpath_cfg.py --endpath --task >& finalpath.log || die "failed test_finalpath_cfg.py --endpath --task" $?
grep "thing '.*' TEST" finalpath.log | diff finalpath_expected_found.log - || die "differences for test_finalpath_cfg.py --endpath --task" $?
-cmsRun ${LOCAL_TEST_DIR}/test_finalpath_cfg.py -- --endpath --task --schedule >& finalpath.log || die "failed test_finalpath_cfg.py --endpath --task --schedule" $?
+cmsRun ${LOCAL_TEST_DIR}/test_finalpath_cfg.py --endpath --task --schedule >& finalpath.log || die "failed test_finalpath_cfg.py --endpath --task --schedule" $?
grep "thing '.*' TEST" finalpath.log | diff finalpath_expected_found.log - || die "differences for test_finalpath_cfg.py --endpath --task --schedule" $?
-cmsRun ${LOCAL_TEST_DIR}/test_finalpath_cfg.py -- --path --task >& finalpath.log || die "failed test_finalpath_cfg.py --path --task" $?
+cmsRun ${LOCAL_TEST_DIR}/test_finalpath_cfg.py --path --task >& finalpath.log || die "failed test_finalpath_cfg.py --path --task" $?
grep "thing '.*' TEST" finalpath.log | diff finalpath_expected_found.log - || die "differences for test_finalpath_cfg.py --path --task" $?
-cmsRun ${LOCAL_TEST_DIR}/test_finalpath_cfg.py -- --path --task --schedule >& finalpath.log || die "failed test_finalpath_cfg.py --path --task --schedule" $?
+cmsRun ${LOCAL_TEST_DIR}/test_finalpath_cfg.py --path --task --schedule >& finalpath.log || die "failed test_finalpath_cfg.py --path --task --schedule" $?
grep "thing '.*' TEST" finalpath.log | diff finalpath_expected_found.log - || die "differences for test_finalpath_cfg.py --path --task --schedule" $?
@@ -68,9 +68,9 @@ found thing 'beginRun' TEST
found thing 'endRun' TEST
EOF
-cmsRun ${LOCAL_TEST_DIR}/test_finalpath_cfg.py -- --path --filter >& finalpath.log || die "failed test_finalpath_cfg.py --path --filter" $?
+cmsRun ${LOCAL_TEST_DIR}/test_finalpath_cfg.py --path --filter >& finalpath.log || die "failed test_finalpath_cfg.py --path --filter" $?
grep "thing '.*' TEST" finalpath.log | diff finalpath_expected_filter.log - || die "differences for test_finalpath_cfg.py --path --filter" $?
-cmsRun ${LOCAL_TEST_DIR}/test_finalpath_cfg.py -- --path --filter --task >& finalpath.log || die "failed test_finalpath_cfg.py --path --filter --task" $?
+cmsRun ${LOCAL_TEST_DIR}/test_finalpath_cfg.py --path --filter --task >& finalpath.log || die "failed test_finalpath_cfg.py --path --filter --task" $?
grep "thing '.*' TEST" finalpath.log | diff finalpath_expected_filter.log - || die "differences for test_finalpath_cfg.py --path --filter --task" $?
diff --git a/FWCore/Integration/test/test_finalpath_cfg.py b/FWCore/Integration/test/test_finalpath_cfg.py
index d427dc9f5a0b9..cd1f4f5ad7320 100644
--- a/FWCore/Integration/test/test_finalpath_cfg.py
+++ b/FWCore/Integration/test/test_finalpath_cfg.py
@@ -12,11 +12,7 @@
parser.add_argument("--tracer", help="add Tracer service", action="store_true")
print(sys.argv)
-argv = sys.argv[:]
-if '--' in argv:
- argv.remove("--")
-args, unknown = parser.parse_known_args(argv)
-
+args = parser.parse_args()
process = cms.Process("TEST")
diff --git a/FWCore/Integration/test/test_shouldTryToContinue_cfg.py b/FWCore/Integration/test/test_shouldTryToContinue_cfg.py
index 4c6c76db9e05e..34f34aed3e395 100644
--- a/FWCore/Integration/test/test_shouldTryToContinue_cfg.py
+++ b/FWCore/Integration/test/test_shouldTryToContinue_cfg.py
@@ -9,10 +9,7 @@
parser.add_argument("--inRun", action = "store_true", help="Throw exception in Run")
parser.add_argument("--inLumi", action = "store_true", help="Throw exception in Lumi")
-argv = sys.argv[:]
-if '--' in argv:
- argv.remove("--")
-args, unknown = parser.parse_known_args(argv)
+args = parser.parse_args()
process = cms.Process("TEST")
diff --git a/FWCore/Integration/test/transRefTest.sh b/FWCore/Integration/test/transRefTest.sh
index 2ce38ece18616..b293282e3c383 100755
--- a/FWCore/Integration/test/transRefTest.sh
+++ b/FWCore/Integration/test/transRefTest.sh
@@ -2,4 +2,4 @@
function die { echo $1: status $2 ; exit $2; }
-cmsRun --parameter-set ${SCRAM_TEST_PATH}/TransRefTest_cfg.py || die 'Failed in TransRefTest_cfg.py' $?
+cmsRun ${SCRAM_TEST_PATH}/TransRefTest_cfg.py || die 'Failed in TransRefTest_cfg.py' $?
diff --git a/FWCore/Integration/test/transformTest_cfg.py b/FWCore/Integration/test/transformTest_cfg.py
index 2699c4a54e7df..0dfd323c1a855 100644
--- a/FWCore/Integration/test/transformTest_cfg.py
+++ b/FWCore/Integration/test/transformTest_cfg.py
@@ -15,11 +15,7 @@
parser.add_argument("--async_", help="use asynchronous module", action="store_true")
parser.add_argument("--exception", help="Make module consumed by transformer to throw an exception", action="store_true")
-argv = sys.argv[:]
-if '--' in argv:
- argv.remove("--")
-args, unknown = parser.parse_known_args(argv)
-
+args = parser.parse_args()
process = cms.Process("TEST")
diff --git a/FWCore/Integration/test/waiting_thread_test.sh b/FWCore/Integration/test/waiting_thread_test.sh
index 7e90abc153802..89b48804fcab3 100755
--- a/FWCore/Integration/test/waiting_thread_test.sh
+++ b/FWCore/Integration/test/waiting_thread_test.sh
@@ -5,4 +5,4 @@ function die { echo $1: status $2 ; exit $2; }
LOCAL_TEST_DIR=${SCRAM_TEST_PATH}
echo "cmsRun acquireTest_cfg.py"
-cmsRun --parameter-set ${LOCAL_TEST_DIR}/acquireTest_cfg.py || die 'Failed in acquireTest_cfg.py' $?
+cmsRun ${LOCAL_TEST_DIR}/acquireTest_cfg.py || die 'Failed in acquireTest_cfg.py' $?
diff --git a/FWCore/MessageService/test/testLoggerInCmsRun.sh b/FWCore/MessageService/test/testLoggerInCmsRun.sh
index 12a05fe379104..22232d043f9f8 100755
--- a/FWCore/MessageService/test/testLoggerInCmsRun.sh
+++ b/FWCore/MessageService/test/testLoggerInCmsRun.sh
@@ -6,5 +6,5 @@ function die { echo $1: status $2 ; exit $2; }
export STD_OUT=./cout.txt
export STD_ERR=./cerr.txt
-#(totalview cmsRun -a --parameter-set ${SCRAM_TEST_PATH}/messageLogger_cfg.py > ${STD_OUT} 2> ${STD_ERR} ) || die 'Failure using messageLogger_cfg.py' $?
-(cmsRun --parameter-set ${SCRAM_TEST_PATH}/messageLogger_cfg.py > ${STD_OUT} 2> ${STD_ERR} ) || die 'Failure using messageLogger_cfg.py' $?
+#(totalview cmsRun -a ${SCRAM_TEST_PATH}/messageLogger_cfg.py > ${STD_OUT} 2> ${STD_ERR} ) || die 'Failure using messageLogger_cfg.py' $?
+(cmsRun ${SCRAM_TEST_PATH}/messageLogger_cfg.py > ${STD_OUT} 2> ${STD_ERR} ) || die 'Failure using messageLogger_cfg.py' $?
diff --git a/FWCore/MessageService/test/u1.sh b/FWCore/MessageService/test/u1.sh
index 7c9af0ec5073a..8a1f0691318d3 100755
--- a/FWCore/MessageService/test/u1.sh
+++ b/FWCore/MessageService/test/u1.sh
@@ -7,7 +7,7 @@ status=0
rm -f u1_errors.log u1_warnings.log u1_infos.log u1_debugs.log u1_default.log u1_job_report.mxml
-cmsRun -j u1_job_report.mxml -p ${SCRAM_TEST_PATH}/u1_cfg.py || exit $?
+cmsRun -j u1_job_report.mxml ${SCRAM_TEST_PATH}/u1_cfg.py || exit $?
for file in u1_errors.log u1_warnings.log u1_infos.log u1_debugs.log u1_default.log u1_job_report.mxml
do
diff --git a/FWCore/MessageService/test/u10.sh b/FWCore/MessageService/test/u10.sh
index f38f4afa5b3bc..a2752ec3d3f13 100755
--- a/FWCore/MessageService/test/u10.sh
+++ b/FWCore/MessageService/test/u10.sh
@@ -7,7 +7,7 @@ status=0
rm -f u10_warnings.log u10_job_report.xml
-cmsRun -j u10_job_report.xml -p ${SCRAM_TEST_PATH}/u10_cfg.py || exit $?
+cmsRun -j u10_job_report.xml ${SCRAM_TEST_PATH}/u10_cfg.py || exit $?
for file in u10_warnings.log u10_job_report.xml
do
diff --git a/FWCore/MessageService/test/u11.sh b/FWCore/MessageService/test/u11.sh
index a12d5410ef8d6..e004cb138f6da 100755
--- a/FWCore/MessageService/test/u11.sh
+++ b/FWCore/MessageService/test/u11.sh
@@ -7,7 +7,7 @@ status=0
rm -f u11_overall_unnamed.log u11_overall_specific.log u11_supercede_specific.log u11_non_supercede_common.log u11_specific.log
-cmsRun -p ${SCRAM_TEST_PATH}/u11_cfg.py || exit $?
+cmsRun ${SCRAM_TEST_PATH}/u11_cfg.py || exit $?
for file in u11_overall_unnamed.log u11_overall_specific.log u11_supercede_specific.log u11_non_supercede_common.log u11_specific.log
do
diff --git a/FWCore/MessageService/test/u12.sh b/FWCore/MessageService/test/u12.sh
index ef1e1fb687a24..7ed4ecbab7635 100755
--- a/FWCore/MessageService/test/u12.sh
+++ b/FWCore/MessageService/test/u12.sh
@@ -7,7 +7,7 @@ status=0
rm -f u12_warnings.log u12_placeholder.log
-cmsRun -p ${SCRAM_TEST_PATH}/u12_cfg.py || exit $?
+cmsRun ${SCRAM_TEST_PATH}/u12_cfg.py || exit $?
for file in u12_warnings.log
do
diff --git a/FWCore/MessageService/test/u13.sh b/FWCore/MessageService/test/u13.sh
index 8f8592eb38bde..8fd5bc5d2fdf6 100755
--- a/FWCore/MessageService/test/u13.sh
+++ b/FWCore/MessageService/test/u13.sh
@@ -7,7 +7,7 @@ status=0
rm -f u13_infos.log u13_debugs.log
-cmsRun -p ${SCRAM_TEST_PATH}/u13_cfg.py || exit $?
+cmsRun ${SCRAM_TEST_PATH}/u13_cfg.py || exit $?
for file in u13_infos.log u13_debugs.log
do
diff --git a/FWCore/MessageService/test/u13d.sh b/FWCore/MessageService/test/u13d.sh
index 149bdf914454c..1bfd8fbe3f196 100755
--- a/FWCore/MessageService/test/u13d.sh
+++ b/FWCore/MessageService/test/u13d.sh
@@ -7,7 +7,7 @@ status=0
rm -f u13d_infos.log u13d_debugs.log
-cmsRun -p ${SCRAM_TEST_PATH}/u13d_cfg.py || exit $?
+cmsRun ${SCRAM_TEST_PATH}/u13d_cfg.py || exit $?
for file in u13d_infos.log u13d_debugs.log
do
diff --git a/FWCore/MessageService/test/u14.sh b/FWCore/MessageService/test/u14.sh
index 4b2a6f18da70a..aa0f4db32b6ff 100755
--- a/FWCore/MessageService/test/u14.sh
+++ b/FWCore/MessageService/test/u14.sh
@@ -7,7 +7,7 @@ status=0
rm -f u14_errors.log u14_warnings.log u14_infos.log u14_debugs.log u14_default.log u14_job_report.mxml
-cmsRun -j u14_job_report.mxml -p ${SCRAM_TEST_PATH}/u14_cfg.py || exit $?
+cmsRun -j u14_job_report.mxml ${SCRAM_TEST_PATH}/u14_cfg.py || exit $?
for file in u14_errors.log u14_warnings.log u14_infos.log u14_debugs.log u14_default.log u14_job_report.mxml
do
diff --git a/FWCore/MessageService/test/u15.sh b/FWCore/MessageService/test/u15.sh
index 127d5162eb952..b58a9e7d24ef7 100755
--- a/FWCore/MessageService/test/u15.sh
+++ b/FWCore/MessageService/test/u15.sh
@@ -7,7 +7,7 @@ status=0
rm -f u15_infos.log u15_debugs.log
-cmsRun -p ${SCRAM_TEST_PATH}/u15_cfg.py || exit $?
+cmsRun ${SCRAM_TEST_PATH}/u15_cfg.py || exit $?
for file in u15_infos.log u15_debugs.log
do
diff --git a/FWCore/MessageService/test/u16.sh b/FWCore/MessageService/test/u16.sh
index a55cfdb57fa41..7a8df4c12fca8 100755
--- a/FWCore/MessageService/test/u16.sh
+++ b/FWCore/MessageService/test/u16.sh
@@ -7,7 +7,7 @@ status=0
rm -f u16_errors.mmlog u16_altWarnings.log u16_infos.mmlog u16_altDebugs.mmlog u16_default.log u16_job_report.mmxml u16_statistics.mslog
-cmsRun -e -j u16_job_report.mmxml -p ${SCRAM_TEST_PATH}/u16_cfg.py || exit $?
+cmsRun -e -j u16_job_report.mmxml ${SCRAM_TEST_PATH}/u16_cfg.py || exit $?
for file in u16_errors.mmlog u16_altWarnings.log u16_infos.mmlog u16_altDebugs.mmlog u16_default.log u16_job_report.mmxml u16_statistics.mslog
do
diff --git a/FWCore/MessageService/test/u17.sh b/FWCore/MessageService/test/u17.sh
index 9434c78820ecd..48b519497efb5 100755
--- a/FWCore/MessageService/test/u17.sh
+++ b/FWCore/MessageService/test/u17.sh
@@ -7,7 +7,7 @@ status=0
rm -f u17_all.log
-cmsRun -p ${SCRAM_TEST_PATH}/u17_cfg.py || exit $?
+cmsRun ${SCRAM_TEST_PATH}/u17_cfg.py || exit $?
for file in u17_all.log
do
diff --git a/FWCore/MessageService/test/u18.sh b/FWCore/MessageService/test/u18.sh
index 4fc3849adde02..42d42283b70da 100755
--- a/FWCore/MessageService/test/u18.sh
+++ b/FWCore/MessageService/test/u18.sh
@@ -7,7 +7,7 @@ status=0
rm -f u18_system.log u18_everything.log
-cmsRun -p ${SCRAM_TEST_PATH}/u18_cfg.py || exit $?
+cmsRun ${SCRAM_TEST_PATH}/u18_cfg.py || exit $?
for file in u18_system.log u18_everything.log
do
diff --git a/FWCore/MessageService/test/u19.sh b/FWCore/MessageService/test/u19.sh
index 8d1d9388f1fe0..d3c72164fb5a2 100755
--- a/FWCore/MessageService/test/u19.sh
+++ b/FWCore/MessageService/test/u19.sh
@@ -7,7 +7,7 @@ status=0
rm -f u19_infos.log u19_debugs.log
-cmsRun -p ${SCRAM_TEST_PATH}/u19_cfg.py || exit $?
+cmsRun ${SCRAM_TEST_PATH}/u19_cfg.py || exit $?
for file in u19_infos.log u19_debugs.log
do
diff --git a/FWCore/MessageService/test/u19d.sh b/FWCore/MessageService/test/u19d.sh
index 47a89f4a8a5c7..1966e857f777d 100755
--- a/FWCore/MessageService/test/u19d.sh
+++ b/FWCore/MessageService/test/u19d.sh
@@ -7,7 +7,7 @@ status=0
rm -f u19d_infos.log u19d_debugs.log
-cmsRun -p ${SCRAM_TEST_PATH}/u19d_cfg.py || exit $?
+cmsRun ${SCRAM_TEST_PATH}/u19d_cfg.py || exit $?
for file in u19d_infos.log u19d_debugs.log
do
diff --git a/FWCore/MessageService/test/u1d.sh b/FWCore/MessageService/test/u1d.sh
index 68b32187d2adf..bfa803aa23369 100755
--- a/FWCore/MessageService/test/u1d.sh
+++ b/FWCore/MessageService/test/u1d.sh
@@ -7,7 +7,7 @@ status=0
rm -f u1d_errors.log u1d_warnings.log u1d_infos.log u1d_debugs.log u1d_default.log u1d_job_report.mxml
-cmsRun -j u1d_job_report.mxml -p ${SCRAM_TEST_PATH}/u1d_cfg.py || exit $?
+cmsRun -j u1d_job_report.mxml ${SCRAM_TEST_PATH}/u1d_cfg.py || exit $?
for file in u1d_errors.log u1d_warnings.log u1d_infos.log u1d_debugs.log u1d_default.log u1d_job_report.mxml
do
diff --git a/FWCore/MessageService/test/u2.sh b/FWCore/MessageService/test/u2.sh
index 9f25de5ca509a..08e9939ad9cee 100755
--- a/FWCore/MessageService/test/u2.sh
+++ b/FWCore/MessageService/test/u2.sh
@@ -7,7 +7,7 @@ status=0
if [ "$UBSAN_OPTIONS" != "" ] ; then export UBSAN_OPTIONS="log_path=ubsan.log:${UBSAN_OPTIONS}"; fi
rm -f u2_warnings.log u2_cerr.mout
-cmsRun -p ${SCRAM_TEST_PATH}/u2_cfg.py 2> ./u2_cerr.mout || exit $?
+cmsRun ${SCRAM_TEST_PATH}/u2_cfg.py 2> ./u2_cerr.mout || exit $?
sed -n '/Disabling gnu++: clang has no __float128 support on this target!/!p' u2_cerr.mout > tmpf && mv tmpf u2_cerr.mout # remove clang output
for file in u2_warnings.log u2_cerr.mout
diff --git a/FWCore/MessageService/test/u20.sh b/FWCore/MessageService/test/u20.sh
index b399f6b7be7b6..826a7260a8324 100755
--- a/FWCore/MessageService/test/u20.sh
+++ b/FWCore/MessageService/test/u20.sh
@@ -7,7 +7,7 @@ status=0
if [ "$UBSAN_OPTIONS" != "" ] ; then export UBSAN_OPTIONS="log_path=ubsan.log:${UBSAN_OPTIONS}"; fi
rm -f u20_cerr.log FrameworkJobReport.xml
-cmsRun -e -p ${SCRAM_TEST_PATH}/u20_cfg.py 2> u20_cerr.log || exit $?
+cmsRun -e ${SCRAM_TEST_PATH}/u20_cfg.py 2> u20_cerr.log || exit $?
sed -n '/Disabling gnu++: clang has no __float128 support on this target!/!p' u20_cerr.log > tmpf && mv tmpf u20_cerr.log # remove clang output
for file in u20_cerr.log FrameworkJobReport.xml
diff --git a/FWCore/MessageService/test/u21.sh b/FWCore/MessageService/test/u21.sh
index 7e7f5409ea21d..987a7e188bfef 100755
--- a/FWCore/MessageService/test/u21.sh
+++ b/FWCore/MessageService/test/u21.sh
@@ -7,7 +7,7 @@ status=0
rm -f u21_warnings.log u21_infos.log
-cmsRun -p ${SCRAM_TEST_PATH}/u21_cfg.py || exit $?
+cmsRun ${SCRAM_TEST_PATH}/u21_cfg.py || exit $?
for file in u21_warnings.log u21_infos.log
do
diff --git a/FWCore/MessageService/test/u22.sh b/FWCore/MessageService/test/u22.sh
index 818b20317a58e..c587cb7d5a3f4 100755
--- a/FWCore/MessageService/test/u22.sh
+++ b/FWCore/MessageService/test/u22.sh
@@ -7,7 +7,7 @@ status=0
rm -f u22_warnings.log
-cmsRun -p ${SCRAM_TEST_PATH}/u22_cfg.py || exit $?
+cmsRun ${SCRAM_TEST_PATH}/u22_cfg.py || exit $?
for file in u22_warnings.log
do
diff --git a/FWCore/MessageService/test/u23.sh b/FWCore/MessageService/test/u23.sh
index dd33d16d193c9..228d54de273c2 100755
--- a/FWCore/MessageService/test/u23.sh
+++ b/FWCore/MessageService/test/u23.sh
@@ -7,7 +7,7 @@ status=0
rm -f u23_infos.log
-cmsRun -p ${SCRAM_TEST_PATH}/u23_cfg.py || exit $?
+cmsRun ${SCRAM_TEST_PATH}/u23_cfg.py || exit $?
for file in u23_infos.log
do
diff --git a/FWCore/MessageService/test/u23t.sh b/FWCore/MessageService/test/u23t.sh
index dd33d16d193c9..228d54de273c2 100755
--- a/FWCore/MessageService/test/u23t.sh
+++ b/FWCore/MessageService/test/u23t.sh
@@ -7,7 +7,7 @@ status=0
rm -f u23_infos.log
-cmsRun -p ${SCRAM_TEST_PATH}/u23_cfg.py || exit $?
+cmsRun ${SCRAM_TEST_PATH}/u23_cfg.py || exit $?
for file in u23_infos.log
do
diff --git a/FWCore/MessageService/test/u24.sh b/FWCore/MessageService/test/u24.sh
index aa59c3255d6aa..30a80c0430f30 100755
--- a/FWCore/MessageService/test/u24.sh
+++ b/FWCore/MessageService/test/u24.sh
@@ -7,7 +7,7 @@ status=0
rm -f u24.log
-cmsRun -p ${SCRAM_TEST_PATH}/u24_cfg.py && exit 1
+cmsRun ${SCRAM_TEST_PATH}/u24_cfg.py && exit 1
for file in u24.log
do
diff --git a/FWCore/MessageService/test/u25.sh b/FWCore/MessageService/test/u25.sh
index aee7310a0d4d6..7d9d5394625ba 100755
--- a/FWCore/MessageService/test/u25.sh
+++ b/FWCore/MessageService/test/u25.sh
@@ -7,7 +7,7 @@ status=0
rm -f u25_only.log
-cmsRun -p ${SCRAM_TEST_PATH}/u25_cfg.py || exit $?
+cmsRun ${SCRAM_TEST_PATH}/u25_cfg.py || exit $?
for file in u25_only.log
do
diff --git a/FWCore/MessageService/test/u28.sh b/FWCore/MessageService/test/u28.sh
index 897aea91ccd05..20cd4aa0901ee 100755
--- a/FWCore/MessageService/test/u28.sh
+++ b/FWCore/MessageService/test/u28.sh
@@ -7,7 +7,7 @@ status=0
rm -f u28_output.log
-cmsRun -p ${SCRAM_TEST_PATH}/u28_cfg.py || exit $?
+cmsRun ${SCRAM_TEST_PATH}/u28_cfg.py || exit $?
for file in u28_output.log
do
diff --git a/FWCore/MessageService/test/u3.sh b/FWCore/MessageService/test/u3.sh
index 8cfa22f025c82..7a8e407500982 100755
--- a/FWCore/MessageService/test/u3.sh
+++ b/FWCore/MessageService/test/u3.sh
@@ -7,8 +7,8 @@ status=0
rm -f u3_infos.log u3_statistics.log
-cmsRun -p ${SCRAM_TEST_PATH}/u3_cfg.py || exit $?
-#/scratch2/mf/CMSSW_1_4_0_pre1/tmp/slc3_ia32_gcc323_dbg/src/FWCore/Framework/bin/cmsRun/cmsRun -p ${SCRAM_TEST_PATH}/u3_cfg.py || exit $?
+cmsRun ${SCRAM_TEST_PATH}/u3_cfg.py || exit $?
+#/scratch2/mf/CMSSW_1_4_0_pre1/tmp/slc3_ia32_gcc323_dbg/src/FWCore/Framework/bin/cmsRun/cmsRun ${SCRAM_TEST_PATH}/u3_cfg.py || exit $?
for file in u3_infos.log u3_statistics.log
do
diff --git a/FWCore/MessageService/test/u30.sh b/FWCore/MessageService/test/u30.sh
index 3e3a9e1db04cf..1da6ddaf91c8a 100755
--- a/FWCore/MessageService/test/u30.sh
+++ b/FWCore/MessageService/test/u30.sh
@@ -7,7 +7,7 @@ status=0
rm -f u30_infos.log
-cmsRun -p ${SCRAM_TEST_PATH}/u30_cfg.py || exit $?
+cmsRun ${SCRAM_TEST_PATH}/u30_cfg.py || exit $?
for file in u30_infos.log
do
diff --git a/FWCore/MessageService/test/u31.sh b/FWCore/MessageService/test/u31.sh
index 7747b3bc3adec..45e7e7923bc6d 100755
--- a/FWCore/MessageService/test/u31.sh
+++ b/FWCore/MessageService/test/u31.sh
@@ -7,7 +7,7 @@ status=0
rm -f u31_infos.log
-cmsRun -p ${SCRAM_TEST_PATH}/u31_cfg.py || exit $?
+cmsRun ${SCRAM_TEST_PATH}/u31_cfg.py || exit $?
for file in u31_infos.log
do
diff --git a/FWCore/MessageService/test/u33.sh b/FWCore/MessageService/test/u33.sh
index 4653d963d8af6..3ef2bfee92dba 100755
--- a/FWCore/MessageService/test/u33.sh
+++ b/FWCore/MessageService/test/u33.sh
@@ -7,7 +7,7 @@ status=0
rm -f u33_all.log
-cmsRun -p ${SCRAM_TEST_PATH}/u33_cfg.py || exit $?
+cmsRun ${SCRAM_TEST_PATH}/u33_cfg.py || exit $?
for file in u33_all.log
do
diff --git a/FWCore/MessageService/test/u33d.sh b/FWCore/MessageService/test/u33d.sh
index 89dde9f2988a3..22169fe7cf785 100755
--- a/FWCore/MessageService/test/u33d.sh
+++ b/FWCore/MessageService/test/u33d.sh
@@ -7,7 +7,7 @@ status=0
rm -f u33d_all.log
-cmsRun -p ${SCRAM_TEST_PATH}/u33d_cfg.py || exit $?
+cmsRun ${SCRAM_TEST_PATH}/u33d_cfg.py || exit $?
for file in u33d_all.log
do
diff --git a/FWCore/MessageService/test/u34.sh b/FWCore/MessageService/test/u34.sh
index 4a3caff07369a..0e44aa4c294d6 100755
--- a/FWCore/MessageService/test/u34.sh
+++ b/FWCore/MessageService/test/u34.sh
@@ -7,7 +7,7 @@ status=0
rm -f u34_warnings.log
-cmsRun -p ${SCRAM_TEST_PATH}/u34_cfg.py || exit $?
+cmsRun ${SCRAM_TEST_PATH}/u34_cfg.py || exit $?
for file in u34_warnings.log
do
diff --git a/FWCore/MessageService/test/u35.sh b/FWCore/MessageService/test/u35.sh
index f49557fe187f9..a37ca12a413b2 100755
--- a/FWCore/MessageService/test/u35.sh
+++ b/FWCore/MessageService/test/u35.sh
@@ -7,7 +7,7 @@ status=0
rm -f u35_infos.log u35_warnings.log
-cmsRun -p ${SCRAM_TEST_PATH}/u35_cfg.py || exit $?
+cmsRun ${SCRAM_TEST_PATH}/u35_cfg.py || exit $?
for file in u35_infos.log u35_warnings.log
do
diff --git a/FWCore/MessageService/test/u36.sh b/FWCore/MessageService/test/u36.sh
index f9108d334321b..3b973657b1cc3 100755
--- a/FWCore/MessageService/test/u36.sh
+++ b/FWCore/MessageService/test/u36.sh
@@ -7,7 +7,7 @@ status=0
rm -f u36_only.log
-cmsRun -p ${SCRAM_TEST_PATH}/u36_cfg.py || exit $?
+cmsRun ${SCRAM_TEST_PATH}/u36_cfg.py || exit $?
for file in u36_only.log
do
diff --git a/FWCore/MessageService/test/u4.sh b/FWCore/MessageService/test/u4.sh
index 060d18863c804..fdd53e4dcaf87 100755
--- a/FWCore/MessageService/test/u4.sh
+++ b/FWCore/MessageService/test/u4.sh
@@ -7,7 +7,7 @@ status=0
rm -f u4_errors.log u4_statistics.log u4_another.log
-cmsRun -p ${SCRAM_TEST_PATH}/u4_cfg.py || exit $?
+cmsRun ${SCRAM_TEST_PATH}/u4_cfg.py || exit $?
for file in u4_errors.log u4_statistics.log u4_another.log
do
diff --git a/FWCore/MessageService/test/u5.sh b/FWCore/MessageService/test/u5.sh
index 65fe8efc8959f..9d5d7f8b1c19b 100755
--- a/FWCore/MessageService/test/u5.sh
+++ b/FWCore/MessageService/test/u5.sh
@@ -7,7 +7,7 @@ status=0
rm -f u5_errors.log u5_default.log u5_noreset.log u5_reset.log
-cmsRun -p ${SCRAM_TEST_PATH}/u5_cfg.py || exit $?
+cmsRun ${SCRAM_TEST_PATH}/u5_cfg.py || exit $?
for file in u5_errors.log u5_default.log u5_noreset.log u5_reset.log
do
diff --git a/FWCore/MessageService/test/u5t.sh b/FWCore/MessageService/test/u5t.sh
index dcfa6d4dcd629..bbfcb4f47af21 100755
--- a/FWCore/MessageService/test/u5t.sh
+++ b/FWCore/MessageService/test/u5t.sh
@@ -7,7 +7,7 @@ status=0
rm -f u5_errors.log u5_default.log u5_noreset.log u5_reset.log
-cmsRun --multithread -p ${SCRAM_TEST_PATH}/u5_cfg.py || exit $?
+cmsRun --multithread ${SCRAM_TEST_PATH}/u5_cfg.py || exit $?
for file in u5_errors.log u5_default.log u5_noreset.log u5_reset.log
do
diff --git a/FWCore/MessageService/test/u6.sh b/FWCore/MessageService/test/u6.sh
index 0af225e7c1516..94682b2a6da07 100755
--- a/FWCore/MessageService/test/u6.sh
+++ b/FWCore/MessageService/test/u6.sh
@@ -7,7 +7,7 @@ status=0
rm -f u6_warnings.log
-cmsRun -p ${SCRAM_TEST_PATH}/u6_cfg.py || exit $?
+cmsRun ${SCRAM_TEST_PATH}/u6_cfg.py || exit $?
for file in u6_warnings.log
do
diff --git a/FWCore/MessageService/test/u7.sh b/FWCore/MessageService/test/u7.sh
index 5cee8b975d54d..f5b1b122bca4e 100755
--- a/FWCore/MessageService/test/u7.sh
+++ b/FWCore/MessageService/test/u7.sh
@@ -7,7 +7,7 @@ status=0
rm -f u7_log.log u7_restrict.log u7_job_report.mxml
-cmsRun -j u7_job_report.mxml -p ${SCRAM_TEST_PATH}/u7_cfg.py || exit $?
+cmsRun -j u7_job_report.mxml ${SCRAM_TEST_PATH}/u7_cfg.py || exit $?
for file in u7_log.log u7_restrict.log u7_job_report.mxml
do
diff --git a/FWCore/MessageService/test/u8.sh b/FWCore/MessageService/test/u8.sh
index ad5d2746f7d61..4e34c287bb527 100755
--- a/FWCore/MessageService/test/u8.sh
+++ b/FWCore/MessageService/test/u8.sh
@@ -7,7 +7,7 @@ status=0
rm -f u8_overall_unnamed.log u8_overall_specific.log u8_supercede_specific.log u8_non_supercede_common.log u8_specific.log
-cmsRun -p ${SCRAM_TEST_PATH}/u8_cfg.py || exit $?
+cmsRun ${SCRAM_TEST_PATH}/u8_cfg.py || exit $?
for file in u8_overall_unnamed.log u8_overall_specific.log u8_supercede_specific.log u8_non_supercede_common.log u8_specific.log
do
diff --git a/FWCore/MessageService/test/u9.sh b/FWCore/MessageService/test/u9.sh
index 82a2639dce734..2d066800fa474 100755
--- a/FWCore/MessageService/test/u9.sh
+++ b/FWCore/MessageService/test/u9.sh
@@ -6,7 +6,7 @@ status=0
rm -f warnings.log infos.log job_report.xml
-cmsRun -j job_report.xml -p ${SCRAM_TEST_PATH}/u9_cfg.py || exit $?
+cmsRun -j job_report.xml ${SCRAM_TEST_PATH}/u9_cfg.py || exit $?
for file in warnings.log infos.log job_report.xml
do
diff --git a/FWCore/ParameterSet/python/VarParsing.py b/FWCore/ParameterSet/python/VarParsing.py
index 0c8819d58ab18..5ac0ece250cd9 100644
--- a/FWCore/ParameterSet/python/VarParsing.py
+++ b/FWCore/ParameterSet/python/VarParsing.py
@@ -364,7 +364,7 @@ def help (self):
print(self)
print("""Options:
help : This screen
- multipleAssign : Allows singletons to have multiple assigments
+ multipleAssign : Allows singletons to have multiple assignments
print : Prints out current values
XXX_clear : Clears list named 'XXX'
""")
diff --git a/FWCore/ParameterSet/python/processFromFile.py b/FWCore/ParameterSet/python/processFromFile.py
new file mode 100644
index 0000000000000..597a48c81dd9e
--- /dev/null
+++ b/FWCore/ParameterSet/python/processFromFile.py
@@ -0,0 +1,19 @@
+import sys
+import types
+from importlib.machinery import SourceFileLoader
+
+def processFromFile(filename, args=None):
+ old_sys_argv = None
+ if args is not None:
+ old_sys_argv = sys.argv[:]
+ sys.argv = [filename]+args
+
+ loader = SourceFileLoader("pycfg", filename)
+ mod = types.ModuleType(loader.name)
+ loader.exec_module(mod)
+ process = mod.process
+
+ if old_sys_argv is not None:
+ sys.argv = old_sys_argv
+
+ return process
diff --git a/FWCore/ParameterSet/scripts/edmConfigDump b/FWCore/ParameterSet/scripts/edmConfigDump
index 8aa68eed26dfc..e70e007376277 100755
--- a/FWCore/ParameterSet/scripts/edmConfigDump
+++ b/FWCore/ParameterSet/scripts/edmConfigDump
@@ -2,9 +2,8 @@
import sys
import os
-from importlib.machinery import SourceFileLoader
-import types
import argparse
+from FWCore.ParameterSet.processFromFile import processFromFile
# make the behaviour of 'cmsRun file.py' and 'edmConfigDump file.py' more consistent
sys.path.append(os.getcwd())
@@ -18,13 +17,11 @@ parser.add_argument("--pruneVerbose", action="store_true",
help="With --prune, be verbose on what is pruned")
parser.add_argument("-o", "--output", type=str, default=None,
help="Save the configuration dump into this file. In this case any printouts from the configuration continue to be printed to stdout. Default is to print the configuration dump to stdout.")
+parser.add_argument("configArgs",
+ nargs=argparse.REMAINDER, help="arguments that will be passed to Python configuration file")
options = parser.parse_args()
-handle = open(options.filename, 'r')
-loader=SourceFileLoader("pycfg", options.filename)
-mod=types.ModuleType(loader.name)
-loader.exec_module(mod)
-cmsProcess= mod.process
+cmsProcess = processFromFile(options.filename, options.configArgs)
if options.prune:
cmsProcess.prune(options.pruneVerbose)
diff --git a/FWCore/ParameterSet/scripts/edmConfigSplit b/FWCore/ParameterSet/scripts/edmConfigSplit
index 281758d08245a..c3c79d29fadef 100755
--- a/FWCore/ParameterSet/scripts/edmConfigSplit
+++ b/FWCore/ParameterSet/scripts/edmConfigSplit
@@ -2,22 +2,17 @@
import sys
import os
-import imp
import argparse
+from FWCore.ParameterSet.processFromFile import processFromFile
from FWCore.ParameterSet.Mixins import PrintOptions
-# customise the HelpFormatter to show additional parameters in the usage line
-class PartialHelpFormatter(argparse.HelpFormatter):
- def _format_usage(self, usage, actions, groups, prefix):
- partial = super(PartialHelpFormatter, self)._format_usage(usage, actions, groups, prefix).strip()
- return partial + ' [--] [OPTIONS ...]\n\n'
-
-
-parser = argparse.ArgumentParser(formatter_class = PartialHelpFormatter,
+parser = argparse.ArgumentParser(
description = '%(prog)s splits the given CMSSW configuration file into one file per top-level object, and outputs the configuration for the main process object.',
- epilog = 'Additional options and arguments are passed to the configuration file unchanged (e.g. for use by VarParsing.py).')
-parser.add_argument('file', metavar = 'FILE', type = argparse.FileType('r'))
+)
+parser.add_argument('file', metavar = 'FILE')
+parser.add_argument("configArgs",
+ nargs=argparse.REMAINDER, help="arguments that will be passed to Python configuration file")
parser.add_argument('-o', '--output',
metavar = 'OUT',
@@ -34,19 +29,12 @@ parser.add_argument('-s', '--subdirectories',
default = False,
help = 'create subdirectories for different modules categories')
-args, other = parser.parse_known_args()
-
-# delete all arguments, so they are not "seen" by the confguration file being split
-del sys.argv[1:]
-sys.argv.append(args.file.name)
-sys.argv.extend(other)
+args = parser.parse_args()
# make the behaviour of 'cmsRun file.py' and 'edmConfigSplit file.py' more consistent
sys.path.append(os.getcwd())
-cfo = imp.load_source("pycfg", args.file.name, args.file)
-process = cfo.process
-args.file.close()
+process = processFromFile(args.file, args.configArgs)
options = PrintOptions()
options.useSubdirectories = args.subdirectories
diff --git a/FWCore/ParameterSet/test/BuildFile.xml b/FWCore/ParameterSet/test/BuildFile.xml
index 7d0a66d540aa7..9538a6c913070 100644
--- a/FWCore/ParameterSet/test/BuildFile.xml
+++ b/FWCore/ParameterSet/test/BuildFile.xml
@@ -17,3 +17,6 @@
+
+
+
diff --git a/FWCore/ParameterSet/test/run_edmConfigDump.sh b/FWCore/ParameterSet/test/run_edmConfigDump.sh
new file mode 100755
index 0000000000000..8ec8763aeaa32
--- /dev/null
+++ b/FWCore/ParameterSet/test/run_edmConfigDump.sh
@@ -0,0 +1,24 @@
+#!/bin/bash
+
+# Pass in name and status
+function die { echo $1: status $2 ; exit $2; }
+
+LOCAL_TEST_DIR="${CMSSW_BASE}/src/FWCore/ParameterSet/test"
+
+function doTest() {
+ TEST="$1"
+ CMD="$2"
+ OUT="$3"
+ REFOUT="${LOCAL_TEST_DIR}/unit_test_outputs/dump.py"
+ LOG="log_test$TEST.log"
+ $CMD >& $LOG || die "Test $TEST: failure running $CMD" $?
+ (diff $REFOUT $OUT) || die "Test $TEST: incorrect output from $CMD" $?
+}
+
+# test edmConfigDump w/ argparse
+OUT=dump_argparse.py
+doTest 1 "edmConfigDump -o $OUT ${LOCAL_TEST_DIR}/test_argparse.py -o foo -i 2" $OUT
+
+# test edmConfigDump w/ varparsing
+OUT=dump_varparsing.py
+doTest 2 "edmConfigDump -o $OUT ${LOCAL_TEST_DIR}/test_varparsing.py output=foo intprod=2" $OUT
diff --git a/FWCore/ParameterSet/test/run_edmConfigSplit.sh b/FWCore/ParameterSet/test/run_edmConfigSplit.sh
new file mode 100755
index 0000000000000..32fc9aea52bdf
--- /dev/null
+++ b/FWCore/ParameterSet/test/run_edmConfigSplit.sh
@@ -0,0 +1,24 @@
+#!/bin/bash
+
+# Pass in name and status
+function die { echo $1: status $2 ; exit $2; }
+
+LOCAL_TEST_DIR="${CMSSW_BASE}/src/FWCore/ParameterSet/test"
+
+function doTest() {
+ TEST="$1"
+ CMD="$2"
+ REFOUT1="${LOCAL_TEST_DIR}/unit_test_outputs/split.py"
+ REFOUT2="${LOCAL_TEST_DIR}/unit_test_outputs/m1a_cfi.py"
+ LOG="log_test$TEST.log"
+ $CMD >& $LOG || die "Test $TEST: failure running $CMD" $?
+ (diff $REFOUT1 $LOG) || die "Test $TEST: incorrect output from $CMD" $?
+ (diff $REFOUT2 m1a_cfi.py) || die "Test $TEST: incorrect output from $CMD" $?
+}
+
+# test edmConfigSplit w/ argparse
+doTest 1 "edmConfigSplit ${LOCAL_TEST_DIR}/test_argparse.py -o foo -i 2"
+
+# test edmConfigSplit w/ varparsing
+OUT=dump_varparsing.py
+doTest 2 "edmConfigSplit ${LOCAL_TEST_DIR}/test_varparsing.py output=foo intprod=2"
diff --git a/FWCore/ParameterSet/test/test_argparse.py b/FWCore/ParameterSet/test/test_argparse.py
new file mode 100644
index 0000000000000..f165294f5dc5e
--- /dev/null
+++ b/FWCore/ParameterSet/test/test_argparse.py
@@ -0,0 +1,26 @@
+import FWCore.ParameterSet.Config as cms
+from argparse import ArgumentParser
+
+parser = ArgumentParser(description='Test argparse')
+parser.add_argument("--maxEvents", help="max events to process", type=int, default=1)
+# same as an edmConfigDump argument
+parser.add_argument("-o", "--output", help="output filename", type=str, default=None)
+# change parameter of tracked module
+parser.add_argument("-i", "--intprod", help="int value to produce", type=int, default=1)
+args = parser.parse_args()
+
+process = cms.Process("TEST")
+process.source = cms.Source("EmptySource")
+
+process.maxEvents.input = args.maxEvents
+
+process.m1a = cms.EDProducer("IntProducer",
+ ivalue = cms.int32(args.intprod)
+)
+process.p1 = cms.Path(process.m1a)
+
+if args.output is not None:
+ process.testout1 = cms.OutputModule("TestOutputModule",
+ name = cms.string(args.output),
+ )
+ process.e1 = cms.EndPath(process.testout1)
diff --git a/FWCore/ParameterSet/test/test_varparsing.py b/FWCore/ParameterSet/test/test_varparsing.py
new file mode 100644
index 0000000000000..156353885c096
--- /dev/null
+++ b/FWCore/ParameterSet/test/test_varparsing.py
@@ -0,0 +1,24 @@
+import FWCore.ParameterSet.Config as cms
+from FWCore.ParameterSet.VarParsing import VarParsing
+
+options = VarParsing()
+options.register("maxEvents", 1, VarParsing.multiplicity.singleton, VarParsing.varType.int, "max events to process")
+options.register("output", "", VarParsing.multiplicity.singleton, VarParsing.varType.string, "output filename")
+options.register("intprod", 1, VarParsing.multiplicity.singleton, VarParsing.varType.int, "int value to produce")
+options.parseArguments()
+
+process = cms.Process("TEST")
+process.source = cms.Source("EmptySource")
+
+process.maxEvents.input = options.maxEvents
+
+process.m1a = cms.EDProducer("IntProducer",
+ ivalue = cms.int32(options.intprod)
+)
+process.p1 = cms.Path(process.m1a)
+
+if len(options.output)>0:
+ process.testout1 = cms.OutputModule("TestOutputModule",
+ name = cms.string(options.output),
+ )
+ process.e1 = cms.EndPath(process.testout1)
diff --git a/FWCore/ParameterSet/test/unit_test_outputs/dump.py b/FWCore/ParameterSet/test/unit_test_outputs/dump.py
new file mode 100644
index 0000000000000..d04da50f2d3fc
--- /dev/null
+++ b/FWCore/ParameterSet/test/unit_test_outputs/dump.py
@@ -0,0 +1,157 @@
+import FWCore.ParameterSet.Config as cms
+
+process = cms.Process("TEST")
+
+process.source = cms.Source("EmptySource")
+process.maxEvents = cms.untracked.PSet(
+ input = cms.untracked.int32(1),
+ output = cms.optional.untracked.allowed(cms.int32,cms.PSet)
+)
+
+process.maxLuminosityBlocks = cms.untracked.PSet(
+ input = cms.untracked.int32(-1)
+)
+
+process.options = cms.untracked.PSet(
+ IgnoreCompletely = cms.untracked.vstring(),
+ Rethrow = cms.untracked.vstring(),
+ TryToContinue = cms.untracked.vstring(),
+ accelerators = cms.untracked.vstring('*'),
+ allowUnscheduled = cms.obsolete.untracked.bool,
+ canDeleteEarly = cms.untracked.vstring(),
+ deleteNonConsumedUnscheduledModules = cms.untracked.bool(True),
+ dumpOptions = cms.untracked.bool(False),
+ emptyRunLumiMode = cms.obsolete.untracked.string,
+ eventSetup = cms.untracked.PSet(
+ forceNumberOfConcurrentIOVs = cms.untracked.PSet(
+ allowAnyLabel_=cms.required.untracked.uint32
+ ),
+ numberOfConcurrentIOVs = cms.untracked.uint32(0)
+ ),
+ fileMode = cms.untracked.string('FULLMERGE'),
+ forceEventSetupCacheClearOnNewRun = cms.untracked.bool(False),
+ holdsReferencesToDeleteEarly = cms.untracked.VPSet(),
+ makeTriggerResults = cms.obsolete.untracked.bool,
+ modulesToCallForTryToContinue = cms.untracked.vstring(),
+ modulesToIgnoreForDeleteEarly = cms.untracked.vstring(),
+ numberOfConcurrentLuminosityBlocks = cms.untracked.uint32(0),
+ numberOfConcurrentRuns = cms.untracked.uint32(1),
+ numberOfStreams = cms.untracked.uint32(0),
+ numberOfThreads = cms.untracked.uint32(1),
+ printDependencies = cms.untracked.bool(False),
+ sizeOfStackForThreadsInKB = cms.optional.untracked.uint32,
+ throwIfIllegalParameter = cms.untracked.bool(True),
+ wantSummary = cms.untracked.bool(False)
+)
+
+process.m1a = cms.EDProducer("IntProducer",
+ ivalue = cms.int32(2)
+)
+
+
+process.testout1 = cms.OutputModule("TestOutputModule",
+ name = cms.string('foo')
+)
+
+
+process.MessageLogger = cms.Service("MessageLogger",
+ cerr = cms.untracked.PSet(
+ FwkReport = cms.untracked.PSet(
+ limit = cms.untracked.int32(10000000),
+ reportEvery = cms.untracked.int32(1)
+ ),
+ FwkSummary = cms.untracked.PSet(
+ limit = cms.untracked.int32(10000000),
+ reportEvery = cms.untracked.int32(1)
+ ),
+ INFO = cms.untracked.PSet(
+ limit = cms.untracked.int32(0)
+ ),
+ Root_NoDictionary = cms.untracked.PSet(
+ limit = cms.untracked.int32(0)
+ ),
+ default = cms.untracked.PSet(
+ limit = cms.untracked.int32(10000000)
+ ),
+ enable = cms.untracked.bool(True),
+ enableStatistics = cms.untracked.bool(False),
+ lineLength = cms.optional.untracked.int32,
+ noLineBreaks = cms.optional.untracked.bool,
+ noTimeStamps = cms.untracked.bool(False),
+ resetStatistics = cms.untracked.bool(False),
+ statisticsThreshold = cms.untracked.string('WARNING'),
+ threshold = cms.untracked.string('INFO'),
+ allowAnyLabel_=cms.optional.untracked.PSetTemplate(
+ limit = cms.optional.untracked.int32,
+ reportEvery = cms.untracked.int32(1),
+ timespan = cms.optional.untracked.int32
+ )
+ ),
+ cout = cms.untracked.PSet(
+ enable = cms.untracked.bool(False),
+ enableStatistics = cms.untracked.bool(False),
+ lineLength = cms.optional.untracked.int32,
+ noLineBreaks = cms.optional.untracked.bool,
+ noTimeStamps = cms.optional.untracked.bool,
+ resetStatistics = cms.untracked.bool(False),
+ statisticsThreshold = cms.optional.untracked.string,
+ threshold = cms.optional.untracked.string,
+ allowAnyLabel_=cms.optional.untracked.PSetTemplate(
+ limit = cms.optional.untracked.int32,
+ reportEvery = cms.untracked.int32(1),
+ timespan = cms.optional.untracked.int32
+ )
+ ),
+ debugModules = cms.untracked.vstring(),
+ default = cms.untracked.PSet(
+ limit = cms.optional.untracked.int32,
+ lineLength = cms.untracked.int32(80),
+ noLineBreaks = cms.untracked.bool(False),
+ noTimeStamps = cms.untracked.bool(False),
+ reportEvery = cms.untracked.int32(1),
+ statisticsThreshold = cms.untracked.string('INFO'),
+ threshold = cms.untracked.string('INFO'),
+ timespan = cms.optional.untracked.int32,
+ allowAnyLabel_=cms.optional.untracked.PSetTemplate(
+ limit = cms.optional.untracked.int32,
+ reportEvery = cms.untracked.int32(1),
+ timespan = cms.optional.untracked.int32
+ )
+ ),
+ files = cms.untracked.PSet(
+ allowAnyLabel_=cms.optional.untracked.PSetTemplate(
+ enableStatistics = cms.untracked.bool(False),
+ extension = cms.optional.untracked.string,
+ filename = cms.optional.untracked.string,
+ lineLength = cms.optional.untracked.int32,
+ noLineBreaks = cms.optional.untracked.bool,
+ noTimeStamps = cms.optional.untracked.bool,
+ output = cms.optional.untracked.string,
+ resetStatistics = cms.untracked.bool(False),
+ statisticsThreshold = cms.optional.untracked.string,
+ threshold = cms.optional.untracked.string,
+ allowAnyLabel_=cms.optional.untracked.PSetTemplate(
+ limit = cms.optional.untracked.int32,
+ reportEvery = cms.untracked.int32(1),
+ timespan = cms.optional.untracked.int32
+ )
+ )
+ ),
+ suppressDebug = cms.untracked.vstring(),
+ suppressFwkInfo = cms.untracked.vstring(),
+ suppressInfo = cms.untracked.vstring(),
+ suppressWarning = cms.untracked.vstring(),
+ allowAnyLabel_=cms.optional.untracked.PSetTemplate(
+ limit = cms.optional.untracked.int32,
+ reportEvery = cms.untracked.int32(1),
+ timespan = cms.optional.untracked.int32
+ )
+)
+
+
+process.p1 = cms.Path(process.m1a)
+
+
+process.e1 = cms.EndPath(process.testout1)
+
+
diff --git a/FWCore/ParameterSet/test/unit_test_outputs/m1a_cfi.py b/FWCore/ParameterSet/test/unit_test_outputs/m1a_cfi.py
new file mode 100644
index 0000000000000..dcb5165a608d6
--- /dev/null
+++ b/FWCore/ParameterSet/test/unit_test_outputs/m1a_cfi.py
@@ -0,0 +1,5 @@
+import FWCore.ParameterSet.Config as cms
+
+m1a = cms.EDProducer("IntProducer",
+ ivalue = cms.int32(2)
+)
diff --git a/FWCore/ParameterSet/test/unit_test_outputs/split.py b/FWCore/ParameterSet/test/unit_test_outputs/split.py
new file mode 100644
index 0000000000000..9d7c4e9cf7f70
--- /dev/null
+++ b/FWCore/ParameterSet/test/unit_test_outputs/split.py
@@ -0,0 +1,13 @@
+import FWCore.ParameterSet.Config as cms
+
+process = cms.Process("TEST")
+
+process.load("source_cfi")
+process.load("m1a_cfi")
+process.load("testout1_cfi")
+process.load("e1_cfi")
+process.load("p1_cfi")
+process.load("maxEvents_cfi")
+process.load("maxLuminosityBlocks_cfi")
+process.load("options_cfi")
+process.load("MessageLogger_cfi")
diff --git a/FWCore/ParameterSetReader/bin/BuildFile.xml b/FWCore/ParameterSetReader/bin/BuildFile.xml
index e0b7fa093679b..8dad107ad6cba 100644
--- a/FWCore/ParameterSetReader/bin/BuildFile.xml
+++ b/FWCore/ParameterSetReader/bin/BuildFile.xml
@@ -3,6 +3,3 @@
-
-
-
diff --git a/FWCore/ParameterSetReader/bin/edmConfigHash.cpp b/FWCore/ParameterSetReader/bin/edmConfigHash.cpp
index e0896c3992e39..0af76d8206f4f 100644
--- a/FWCore/ParameterSetReader/bin/edmConfigHash.cpp
+++ b/FWCore/ParameterSetReader/bin/edmConfigHash.cpp
@@ -17,6 +17,7 @@
int main(int argc, char** argv) try {
// config can either be a name or a string
std::string config;
+ std::vector pythonArgs;
if (argc == 1) {
// Read input from cin into configstring..
@@ -25,11 +26,15 @@ int main(int argc, char** argv) try {
config += line;
config += '\n';
}
- } else if (argc == 2) {
+ } else {
config = std::string(argv[1]);
+ pythonArgs.reserve(argc - 1);
+ for (int iarg = 1; iarg < argc; ++iarg) {
+ pythonArgs.push_back(argv[iarg]);
+ }
}
- std::shared_ptr parameterSet = edm::readConfig(config);
+ std::shared_ptr parameterSet = edm::readConfig(config, pythonArgs);
parameterSet->registerIt();
std::cout << parameterSet->id() << std::endl;
return 0;
diff --git a/FWCore/ParameterSetReader/bin/edmParameterSetDump.cpp b/FWCore/ParameterSetReader/bin/edmParameterSetDump.cpp
deleted file mode 100644
index 13e786096291a..0000000000000
--- a/FWCore/ParameterSetReader/bin/edmParameterSetDump.cpp
+++ /dev/null
@@ -1,36 +0,0 @@
-// -*- C++ -*-
-//
-// Package: PythonParameterSet
-// Class : edmParameterSetDump
-//
-// Implementation:
-//
-//
-// Original Author: Rick Wilkinson
-// Created: Thu Aug 2 13:33:53 EDT 2007
-//
-
-#include "FWCore/ParameterSet/interface/ParameterSet.h"
-#include "FWCore/ParameterSetReader/interface/ParameterSetReader.h"
-#include "FWCore/Utilities/interface/Exception.h"
-
-#include
-#include
-#include
-
-int main(int argc, char** argv) try {
- if (argc != 2) {
- std::cout << "Usage: edmParameterSetDump " << std::endl;
- }
- std::string fileName(argv[1]);
- std::shared_ptr parameterSet = edm::readConfig(fileName);
- std::cout << "====Main Process====" << std::endl;
- std::cout << parameterSet->dump() << std::endl;
- return 0;
-} catch (cms::Exception const& e) {
- std::cout << e.explainSelf() << std::endl;
- return 1;
-} catch (std::exception const& e) {
- std::cout << e.what() << std::endl;
- return 1;
-}
diff --git a/FWCore/ParameterSetReader/interface/ParameterSetReader.h b/FWCore/ParameterSetReader/interface/ParameterSetReader.h
index 099a3b65c8b92..874cc65949b0c 100644
--- a/FWCore/ParameterSetReader/interface/ParameterSetReader.h
+++ b/FWCore/ParameterSetReader/interface/ParameterSetReader.h
@@ -7,7 +7,7 @@ namespace edm {
std::unique_ptr getPSetFromConfig(const std::string& config);
- std::unique_ptr readConfig(std::string const& config, int argc, char* argv[]);
+ std::unique_ptr readConfig(std::string const& config, const std::vector& args);
std::unique_ptr readConfig(std::string const& config);
diff --git a/FWCore/ParameterSetReader/src/ParameterSetReader.cc b/FWCore/ParameterSetReader/src/ParameterSetReader.cc
index a18046c7bdac3..54ef972bd7f36 100644
--- a/FWCore/ParameterSetReader/src/ParameterSetReader.cc
+++ b/FWCore/ParameterSetReader/src/ParameterSetReader.cc
@@ -3,13 +3,13 @@
#include "FWCore/PythonParameterSet/interface/MakePyBind11ParameterSets.h"
std::unique_ptr edm::getPSetFromConfig(const std::string& config) {
- return PyBind11ProcessDesc(config).parameterSet();
+ return PyBind11ProcessDesc(config, false).parameterSet();
}
//its really the stuff in MakePythonParameterSets that should be in the different namespace
//I'll do that if this setup is ok
-std::unique_ptr edm::readConfig(std::string const& config, int argc, char* argv[]) {
- return edm::cmspybind11::readConfig(config, argc, argv);
+std::unique_ptr edm::readConfig(std::string const& config, const std::vector& args) {
+ return edm::cmspybind11::readConfig(config, args);
}
std::unique_ptr edm::readConfig(std::string const& config) {
diff --git a/FWCore/PythonParameterSet/interface/MakePyBind11ParameterSets.h b/FWCore/PythonParameterSet/interface/MakePyBind11ParameterSets.h
index d672025d120e6..f61545d552c91 100644
--- a/FWCore/PythonParameterSet/interface/MakePyBind11ParameterSets.h
+++ b/FWCore/PythonParameterSet/interface/MakePyBind11ParameterSets.h
@@ -17,7 +17,7 @@ namespace edm {
std::unique_ptr readConfig(std::string const& config);
/// same, but with arguments
- std::unique_ptr readConfig(std::string const& config, int argc, char* argv[]);
+ std::unique_ptr readConfig(std::string const& config, const std::vector& args);
/// essentially the same as the previous method
void makeParameterSets(std::string const& configtext, std::unique_ptr& main);
diff --git a/FWCore/PythonParameterSet/interface/PyBind11ProcessDesc.h b/FWCore/PythonParameterSet/interface/PyBind11ProcessDesc.h
index bf56d72167c60..0bfcf988456d6 100644
--- a/FWCore/PythonParameterSet/interface/PyBind11ProcessDesc.h
+++ b/FWCore/PythonParameterSet/interface/PyBind11ProcessDesc.h
@@ -33,9 +33,9 @@ class PyBind11ProcessDesc {
It decides whether it's a file or string by seeing if
it ends in '.py'
*/
- PyBind11ProcessDesc(std::string const& config);
+ PyBind11ProcessDesc(std::string const& config, bool isFile);
- PyBind11ProcessDesc(std::string const& config, int argc, char* argv[]);
+ PyBind11ProcessDesc(std::string const& config, bool isFile, const std::vector& args);
~PyBind11ProcessDesc();
@@ -54,7 +54,7 @@ class PyBind11ProcessDesc {
private:
void prepareToRead();
- void read(std::string const& config);
+ void read(std::string const& config, bool isFile);
void readFile(std::string const& fileName);
void readString(std::string const& pyConfig);
diff --git a/FWCore/PythonParameterSet/src/MakePyBind11ParameterSets.cc b/FWCore/PythonParameterSet/src/MakePyBind11ParameterSets.cc
index dc8c22604054e..8310b1b43569d 100644
--- a/FWCore/PythonParameterSet/src/MakePyBind11ParameterSets.cc
+++ b/FWCore/PythonParameterSet/src/MakePyBind11ParameterSets.cc
@@ -24,17 +24,17 @@ static void makePSetsFromString(std::string const& module) {
namespace edm {
namespace cmspybind11 {
std::unique_ptr readConfig(std::string const& config) {
- PyBind11ProcessDesc pythonProcessDesc(config);
+ PyBind11ProcessDesc pythonProcessDesc(config, true);
return pythonProcessDesc.parameterSet();
}
- std::unique_ptr readConfig(std::string const& config, int argc, char* argv[]) {
- PyBind11ProcessDesc pythonProcessDesc(config, argc, argv);
+ std::unique_ptr readConfig(std::string const& config, const std::vector& args) {
+ PyBind11ProcessDesc pythonProcessDesc(config, true, args);
return pythonProcessDesc.parameterSet();
}
void makeParameterSets(std::string const& configtext, std::unique_ptr& main) {
- PyBind11ProcessDesc pythonProcessDesc(configtext);
+ PyBind11ProcessDesc pythonProcessDesc(configtext, false);
main = pythonProcessDesc.parameterSet();
}
diff --git a/FWCore/PythonParameterSet/src/PyBind11Module.h b/FWCore/PythonParameterSet/src/PyBind11Module.h
index dc7ad541da533..a91b74ea7c9ea 100644
--- a/FWCore/PythonParameterSet/src/PyBind11Module.h
+++ b/FWCore/PythonParameterSet/src/PyBind11Module.h
@@ -164,7 +164,7 @@ PYBIND11_MODULE(libFWCorePythonParameterSet, m) {
pybind11::class_(m, "ProcessDesc") //, pybind11::init<>())
.def(pybind11::init<>())
- .def(pybind11::init())
+ .def(pybind11::init())
.def("newPSet", &PyBind11ProcessDesc::newPSet)
.def("pset", &PyBind11ProcessDesc::pset, pybind11::return_value_policy::reference)
.def("dump", &PyBind11ProcessDesc::dump);
diff --git a/FWCore/PythonParameterSet/src/PyBind11ProcessDesc.cc b/FWCore/PythonParameterSet/src/PyBind11ProcessDesc.cc
index 8ca5a44b4d635..af4f9784c746c 100644
--- a/FWCore/PythonParameterSet/src/PyBind11ProcessDesc.cc
+++ b/FWCore/PythonParameterSet/src/PyBind11ProcessDesc.cc
@@ -25,39 +25,33 @@ PyBind11InterpreterSentry::~PyBind11InterpreterSentry() {
PyBind11ProcessDesc::PyBind11ProcessDesc() : theProcessPSet(), theInterpreter(false) {}
-PyBind11ProcessDesc::PyBind11ProcessDesc(std::string const& config) : theProcessPSet(), theInterpreter(true) {
+PyBind11ProcessDesc::PyBind11ProcessDesc(std::string const& config, bool isFile)
+ : theProcessPSet(), theInterpreter(true) {
edm::python::initializePyBind11Module();
prepareToRead();
- read(config);
+ read(config, isFile);
}
-PyBind11ProcessDesc::PyBind11ProcessDesc(std::string const& config, int argc, char* argv[])
- : theProcessPSet(),
- theInterpreter(true)
-
-{
+PyBind11ProcessDesc::PyBind11ProcessDesc(std::string const& config, bool isFile, const std::vector& args)
+ : theProcessPSet(), theInterpreter(true) {
edm::python::initializePyBind11Module();
prepareToRead();
{
-#if PY_MAJOR_VERSION >= 3
typedef std::unique_ptr WArgUPtr;
std::vector v_argv;
std::vector vp_argv;
- v_argv.reserve(argc);
- vp_argv.reserve(argc);
- for (int i = 0; i < argc; i++) {
- v_argv.emplace_back(Py_DecodeLocale(argv[i], nullptr), &PyMem_RawFree);
+ v_argv.reserve(args.size());
+ vp_argv.reserve(args.size());
+ for (size_t i = 0; i < args.size(); i++) {
+ v_argv.emplace_back(Py_DecodeLocale(args[i].c_str(), nullptr), &PyMem_RawFree);
vp_argv.emplace_back(v_argv.back().get());
}
wchar_t** argvt = vp_argv.data();
-#else
- char** argvt = argv;
-#endif
- PySys_SetArgv(argc, argvt);
+ PySys_SetArgv(args.size(), argvt);
}
- read(config);
+ read(config, isFile);
}
PyBind11ProcessDesc::~PyBind11ProcessDesc() = default;
@@ -69,14 +63,12 @@ void PyBind11ProcessDesc::prepareToRead() {
theInterpreter.mainModule.attr("processPSet") = &theProcessPSet;
}
-void PyBind11ProcessDesc::read(std::string const& config) {
+void PyBind11ProcessDesc::read(std::string const& config, bool isFile) {
try {
- // if it ends with py, it's a file
- if (config.substr(config.size() - 3) == ".py") {
+ if (isFile)
readFile(config);
- } else {
+ else
readString(config);
- }
} catch (pybind11::error_already_set const& e) {
edm::pythonToCppException("Configuration", e.what());
}
diff --git a/FWCore/PythonParameterSet/test/makeprocess_t.cppunit.cc b/FWCore/PythonParameterSet/test/makeprocess_t.cppunit.cc
index bab29a0f85806..780278f6db145 100644
--- a/FWCore/PythonParameterSet/test/makeprocess_t.cppunit.cc
+++ b/FWCore/PythonParameterSet/test/makeprocess_t.cppunit.cc
@@ -54,7 +54,7 @@ class testmakeprocess : public CppUnit::TestFixture {
typedef std::shared_ptr ParameterSetPtr;
ParameterSetPtr pSet(char const* c) {
//ParameterSetPtr result( new edm::ProcessDesc(std::string(c)) );
- ParameterSetPtr result = PyBind11ProcessDesc(std::string(c)).parameterSet();
+ ParameterSetPtr result = PyBind11ProcessDesc(std::string(c), false).parameterSet();
CPPUNIT_ASSERT(result->getParameter("@process_name") == "test");
return result;
}
diff --git a/FWCore/PythonParameterSet/test/makepset_t.cppunit.cc b/FWCore/PythonParameterSet/test/makepset_t.cppunit.cc
index b8b2335fdab25..c51dacdef4e43 100644
--- a/FWCore/PythonParameterSet/test/makepset_t.cppunit.cc
+++ b/FWCore/PythonParameterSet/test/makepset_t.cppunit.cc
@@ -93,7 +93,7 @@ void testmakepset::secsourceAux() {
std::string config(kTest);
// Create the ParameterSet object from this configuration string.
- PyBind11ProcessDesc builder(config);
+ PyBind11ProcessDesc builder(config, false);
std::shared_ptr ps = builder.parameterSet();
CPPUNIT_ASSERT(nullptr != ps.get());
@@ -149,7 +149,7 @@ void testmakepset::usingBlockAux() {
std::string config(kTest);
// Create the ParameterSet object from this configuration string.
- PyBind11ProcessDesc builder(config);
+ PyBind11ProcessDesc builder(config, false);
std::shared_ptr ps = builder.parameterSet();
CPPUNIT_ASSERT(nullptr != ps.get());
@@ -199,7 +199,7 @@ void testmakepset::fileinpathAux() {
bool localArea = false;
// Create the ParameterSet object from this configuration string.
{
- PyBind11ProcessDesc builder(config);
+ PyBind11ProcessDesc builder(config, false);
std::shared_ptr ps = builder.parameterSet();
CPPUNIT_ASSERT(nullptr != ps.get());
@@ -277,7 +277,7 @@ void testmakepset::fileinpathAux() {
std::string config2(kTest2);
// Create the ParameterSet object from this configuration string.
- PyBind11ProcessDesc builder2(config2);
+ PyBind11ProcessDesc builder2(config2, false);
unlink(tmpout.c_str());
std::shared_ptr ps2 = builder2.parameterSet();
@@ -357,7 +357,7 @@ void testmakepset::typesTest() {
std::string config2(kTest);
// Create the ParameterSet object from this configuration string.
- PyBind11ProcessDesc builder2(config2);
+ PyBind11ProcessDesc builder2(config2, false);
std::shared_ptr ps2 = builder2.parameterSet();
edm::ParameterSet const& test = ps2->getParameterSet("p");
diff --git a/FWCore/PythonParameterSet/test/processbuilder_t.cppunit.cpp b/FWCore/PythonParameterSet/test/processbuilder_t.cppunit.cpp
index c12b785eed1da..f09a92101ce6c 100644
--- a/FWCore/PythonParameterSet/test/processbuilder_t.cppunit.cpp
+++ b/FWCore/PythonParameterSet/test/processbuilder_t.cppunit.cpp
@@ -65,7 +65,7 @@ void testProcessDesc::trivialPathTest() {
"process.c = cms.EDProducer('C')\n"
"process.p = cms.Path(process.a*process.b*process.c)\n";
- std::shared_ptr test = PyBind11ProcessDesc(str).parameterSet();
+ std::shared_ptr test = PyBind11ProcessDesc(str, false).parameterSet();
typedef std::vector Strs;
@@ -89,7 +89,7 @@ void testProcessDesc::simplePathTest() {
")\n"
"process.p = cms.Path(process.a*process.b*process.c)\n";
- std::shared_ptr test = PyBind11ProcessDesc(str).parameterSet();
+ std::shared_ptr test = PyBind11ProcessDesc(str, false).parameterSet();
typedef std::vector Strs;
@@ -129,7 +129,7 @@ void testProcessDesc::attriggertest() {
"process.epath = cms.EndPath(process.output)\n";
try {
- std::shared_ptr test = PyBind11ProcessDesc(str).parameterSet();
+ std::shared_ptr test = PyBind11ProcessDesc(str, false).parameterSet();
typedef std::vector Strs;
@@ -182,7 +182,7 @@ void testProcessDesc::sequenceSubstitutionTest() {
"process.jets = cms.Sequence(process.somejet1*process.somejet2)\n"
"process.path1 = cms.Path(process.cones*process.jets*process.jtanalyzer)\n";
- std::shared_ptr test = PyBind11ProcessDesc(str).parameterSet();
+ std::shared_ptr test = PyBind11ProcessDesc(str, false).parameterSet();
typedef std::vector Strs;
@@ -211,7 +211,7 @@ void testProcessDesc::nestedSequenceSubstitutionTest() {
"process.s1 = cms.Sequence( process.a+ process.b)\n"
"process.s2 = cms.Sequence(process.s1+ process.c)\n"
"process.path1 = cms.Path(process.s2+process.d)\n";
- std::shared_ptr test = PyBind11ProcessDesc(str).parameterSet();
+ std::shared_ptr test = PyBind11ProcessDesc(str, false).parameterSet();
typedef std::vector Strs;
@@ -241,7 +241,7 @@ void testProcessDesc::sequenceSubstitutionTest2() {
"process.jets = cms.Sequence(process.somejet1+ process.somejet2)\n"
"process.path1 = cms.Path(process.cones+process.jets+ process.jtanalyzer)\n";
- std::shared_ptr test = PyBind11ProcessDesc(str).parameterSet();
+ std::shared_ptr test = PyBind11ProcessDesc(str, false).parameterSet();
typedef std::vector Strs;
@@ -284,7 +284,7 @@ void testProcessDesc::sequenceSubstitutionTest3() {
"process.s3 = cms.Sequence(process.aaa*process.bbb*~process.ccc*process.ddd*process.eee)\n"
"process.path1 = cms.Path(process.s1+process.s3+process.s2+process.last)\n";
- std::shared_ptr test = PyBind11ProcessDesc(str).parameterSet();
+ std::shared_ptr test = PyBind11ProcessDesc(str, false).parameterSet();
typedef std::vector Strs;
@@ -335,7 +335,7 @@ void testProcessDesc::multiplePathsTest() {
"process.path2 = cms.Path(process.jets+ process.anotherjtanalyzer)\n"
"process.schedule = cms.Schedule(process.path2, process.path1)\n";
- std::shared_ptr test = PyBind11ProcessDesc(str).parameterSet();
+ std::shared_ptr test = PyBind11ProcessDesc(str, false).parameterSet();
typedef std::vector Strs;
@@ -374,7 +374,7 @@ void testProcessDesc::inconsistentPathTest() {
"process.b = cms.EDProducer('PhonyConeJet', i = cms.int32(7))\n"
"process.c = cms.EDProducer('PhonyJet', i = cms.int32(7))\n"
"process.path1 = cms.Path((process.a*process.b)+ (process.c*process.b))\n";
- std::shared_ptr test = PyBind11ProcessDesc(str).parameterSet();
+ std::shared_ptr test = PyBind11ProcessDesc(str, false).parameterSet();
}
void testProcessDesc::inconsistentMultiplePathTest() {
@@ -391,7 +391,7 @@ void testProcessDesc::inconsistentMultiplePathTest() {
"process.path1 = cms.Path(process.cones*process.jtanalyzer)\n"
"process.path2 = cms.Path(process.jets*process.jtanalyzer)\n";
- std::shared_ptr test = PyBind11ProcessDesc(str).parameterSet();
+ std::shared_ptr test = PyBind11ProcessDesc(str, false).parameterSet();
}
#include
diff --git a/FWCore/Services/test/test_resourceInformationService.sh b/FWCore/Services/test/test_resourceInformationService.sh
index ab51a92e9e220..ac98a40ef1bf9 100755
--- a/FWCore/Services/test/test_resourceInformationService.sh
+++ b/FWCore/Services/test/test_resourceInformationService.sh
@@ -2,7 +2,7 @@
function die { echo Failure $1: status $2 ; exit $2 ; }
-cmsRun -p ${SCRAM_TEST_PATH}/test_resourceInformationService_cfg.py &> test_resourceInformationService.log || die "cmsRun test_resourceInformationService_cfg.py" $?
+cmsRun ${SCRAM_TEST_PATH}/test_resourceInformationService_cfg.py &> test_resourceInformationService.log || die "cmsRun test_resourceInformationService_cfg.py" $?
grep -A 1 "acceleratorTypes:" test_resourceInformationService.log | grep "GPU" || die "Check for existence of GPU acceleratorType" $?
grep -A 1 "cpu models:" test_resourceInformationService.log | grep "None" && die "Check there is at least one model (not None)" 1
diff --git a/FWCore/TestProcessor/src/TestProcessor.cc b/FWCore/TestProcessor/src/TestProcessor.cc
index 18172abb7857e..b6da72f8125ae 100644
--- a/FWCore/TestProcessor/src/TestProcessor.cc
+++ b/FWCore/TestProcessor/src/TestProcessor.cc
@@ -90,7 +90,7 @@ namespace edm {
//Setup various singletons
(void)oneTimeInitialization();
- ProcessDescImpl desc(iConfig.pythonConfiguration());
+ ProcessDescImpl desc(iConfig.pythonConfiguration(), false);
auto psetPtr = desc.parameterSet();
moduleTypeResolverMaker_ = makeModuleTypeResolverMaker(*psetPtr);
diff --git a/HeterogeneousCore/AlpakaTest/test/testAlpakaModules.sh b/HeterogeneousCore/AlpakaTest/test/testAlpakaModules.sh
index 4a78464a57463..23c5a06b3743b 100755
--- a/HeterogeneousCore/AlpakaTest/test/testAlpakaModules.sh
+++ b/HeterogeneousCore/AlpakaTest/test/testAlpakaModules.sh
@@ -43,25 +43,25 @@ function runFailure {
echo
}
-runSuccess "-- --accelerators=cpu --expectBackend=serial_sync"
-runSuccess "-- --moduleBackend=serial_sync --expectBackend=serial_sync"
+runSuccess "--accelerators=cpu --expectBackend=serial_sync"
+runSuccess "--moduleBackend=serial_sync --expectBackend=serial_sync"
if [ "${TARGET}" == "cpu" ]; then
- runSuccess "-- --expectBackend=serial_sync"
+ runSuccess "--expectBackend=serial_sync"
- runFailure "-- --accelerators=gpu-nvidia --expectBackend=cuda_async"
- runFailure "-- --moduleBackend=cuda_async --expectBackend=cuda_async"
+ runFailure "--accelerators=gpu-nvidia --expectBackend=cuda_async"
+ runFailure "--moduleBackend=cuda_async --expectBackend=cuda_async"
- runSuccessHostAndDevice "-- --expectBackend=serial_sync"
+ runSuccessHostAndDevice "--expectBackend=serial_sync"
elif [ "${TARGET}" == "cuda" ]; then
- runSuccess "-- --expectBackend=cuda_async"
- runSuccess "-- --accelerators=gpu-nvidia --expectBackend=cuda_async"
- runSuccess "-- --moduleBackend=cuda_async --expectBackend=cuda_async"
+ runSuccess "--expectBackend=cuda_async"
+ runSuccess "--accelerators=gpu-nvidia --expectBackend=cuda_async"
+ runSuccess "--moduleBackend=cuda_async --expectBackend=cuda_async"
- runFailure "-- --accelerators=gpu-nvidia --moduleBackend=serial_sync --expectBackend=serial_sync"
- runFailure "-- --accelerators=cpu --moduleBackend=cuda_async --expectBackend=cuda_async"
+ runFailure "--accelerators=gpu-nvidia --moduleBackend=serial_sync --expectBackend=serial_sync"
+ runFailure "--accelerators=cpu --moduleBackend=cuda_async --expectBackend=cuda_async"
- runSuccessHostAndDevice "-- --expectBackend=cuda_async"
+ runSuccessHostAndDevice "--expectBackend=cuda_async"
fi
diff --git a/HeterogeneousCore/AlpakaTest/test/testAlpakaModulesHostAndDevice_cfg.py b/HeterogeneousCore/AlpakaTest/test/testAlpakaModulesHostAndDevice_cfg.py
index d9a63f8b23f42..8f76df6c278c1 100644
--- a/HeterogeneousCore/AlpakaTest/test/testAlpakaModulesHostAndDevice_cfg.py
+++ b/HeterogeneousCore/AlpakaTest/test/testAlpakaModulesHostAndDevice_cfg.py
@@ -12,10 +12,7 @@
parser.add_argument("--expectBackend", type=str, help="Expect this backend to run")
parser.add_argument("--run", type=int, help="Run number (default: 1)", default=1)
-argv = sys.argv[:]
-if '--' in argv:
- argv.remove("--")
-args, unknown = parser.parse_known_args(argv)
+args = parser.parse_args()
process = cms.Process('TEST')
diff --git a/HeterogeneousCore/AlpakaTest/test/testAlpakaModules_cfg.py b/HeterogeneousCore/AlpakaTest/test/testAlpakaModules_cfg.py
index 47a9fdc4b7474..cb66b53bfc55e 100644
--- a/HeterogeneousCore/AlpakaTest/test/testAlpakaModules_cfg.py
+++ b/HeterogeneousCore/AlpakaTest/test/testAlpakaModules_cfg.py
@@ -9,10 +9,7 @@
parser.add_argument("--expectBackend", type=str, help="Expect this backend to run")
parser.add_argument("--run", type=int, help="Run number (default: 1)", default=1)
-argv = sys.argv[:]
-if '--' in argv:
- argv.remove("--")
-args, unknown = parser.parse_known_args(argv)
+args = parser.parse_args()
process = cms.Process('TEST')
diff --git a/HeterogeneousCore/CUDACore/test/test_ProcessAcceleratorCUDA.cc b/HeterogeneousCore/CUDACore/test/test_ProcessAcceleratorCUDA.cc
index 44336a993efbd..b4826ff59e523 100644
--- a/HeterogeneousCore/CUDACore/test/test_ProcessAcceleratorCUDA.cc
+++ b/HeterogeneousCore/CUDACore/test/test_ProcessAcceleratorCUDA.cc
@@ -42,9 +42,10 @@ TEST_CASE("Configuration", s_tag) {
const std::string baseConfig_cuda = makeConfig(test1, test2, "'gpu-nvidia'");
SECTION("Configuration hash is not changed") {
- auto pset_auto = edm::readConfig(baseConfig_auto);
- auto pset_cpu = edm::readConfig(baseConfig_cpu);
- auto pset_cuda = edm::readConfig(baseConfig_cuda);
+ std::unique_ptr pset_auto, pset_cpu, pset_cuda;
+ edm::makeParameterSets(baseConfig_auto, pset_auto);
+ edm::makeParameterSets(baseConfig_cpu, pset_cpu);
+ edm::makeParameterSets(baseConfig_cuda, pset_cuda);
pset_auto->registerIt();
pset_cpu->registerIt();
pset_cuda->registerIt();
diff --git a/HeterogeneousCore/CUDATest/test/runtests.sh b/HeterogeneousCore/CUDATest/test/runtests.sh
index ab35f802917c7..747e26830897d 100755
--- a/HeterogeneousCore/CUDATest/test/runtests.sh
+++ b/HeterogeneousCore/CUDATest/test/runtests.sh
@@ -24,20 +24,20 @@ fi
echo "*************************************************"
echo "CUDA producer configuration with SwitchProducer, automatic"
-cmsRun ${TEST_DIR}/testCUDASwitch_cfg.py -- --silent || die "cmsRun testCUDASwitch_cfg.py --silent" $?
+cmsRun ${TEST_DIR}/testCUDASwitch_cfg.py --silent || die "cmsRun testCUDASwitch_cfg.py --silent" $?
echo "*************************************************"
echo "CUDA producer configuration with SwitchProducer, force CPU"
-cmsRun ${TEST_DIR}/testCUDASwitch_cfg.py -- --silent --accelerator="cpu" || die "cmsRun testCUDASwitch_cfg.py --silent --accelerator=\"\"" $?
+cmsRun ${TEST_DIR}/testCUDASwitch_cfg.py --silent --accelerator="cpu" || die "cmsRun testCUDASwitch_cfg.py --silent --accelerator=\"\"" $?
if [ "x${TARGET}" == "xgpu" ]; then
echo "*************************************************"
echo "CUDA producer configuration with SwitchProducer, force GPU"
- cmsRun ${TEST_DIR}/testCUDASwitch_cfg.py -- --silent --accelerator="gpu-nvidia" || die "cmsRun testCUDASwitch_cfg.py --silent --accelerator=gpu-nvidia" $?
+ cmsRun ${TEST_DIR}/testCUDASwitch_cfg.py --silent --accelerator="gpu-nvidia" || die "cmsRun testCUDASwitch_cfg.py --silent --accelerator=gpu-nvidia" $?
elif [ "x${TARGET}" == "xcpu" ]; then
echo "*************************************************"
echo "CUDA producer configuration with SwitchProducer, force GPU, should fail"
- cmsRun -j testCUDATest_jobreport.xml ${TEST_DIR}/testCUDASwitch_cfg.py -- --silent --accelerator="gpu-nvidia" && die "cmsRun testCUDASwitch_cfg.py --silent --accelerator=gpu-nvidia did not fail" 1
+ cmsRun -j testCUDATest_jobreport.xml ${TEST_DIR}/testCUDASwitch_cfg.py --silent --accelerator="gpu-nvidia" && die "cmsRun testCUDASwitch_cfg.py --silent --accelerator=gpu-nvidia did not fail" 1
EXIT_CODE=$(edmFjrDump --exitCode testCUDATest_jobreport.xml)
if [ "x${EXIT_CODE}" != "x8035" ]; then
echo "Test (that was expected to fail) reported exit code ${EXIT_CODE} instead of expected 8035"
diff --git a/HeterogeneousCore/CUDATest/test/testCUDASwitch_cfg.py b/HeterogeneousCore/CUDATest/test/testCUDASwitch_cfg.py
index 944c1c765ad7d..50cb2c09260cf 100644
--- a/HeterogeneousCore/CUDATest/test/testCUDASwitch_cfg.py
+++ b/HeterogeneousCore/CUDATest/test/testCUDASwitch_cfg.py
@@ -9,10 +9,7 @@
parser.add_argument("--includeAnalyzer", help="Include an EDAnalyzer", action="store_true")
parser.add_argument("--accelerator", type=str, help="String for accelerator to enable")
-argv = sys.argv[:]
-if '--' in argv:
- argv.remove("--")
-args, unknown = parser.parse_known_args(argv)
+args = parser.parse_args()
process = cms.Process("Test")
process.load("FWCore.MessageService.MessageLogger_cfi")
diff --git a/PhysicsTools/PatExamples/bin/PatBasicFWLiteJetAnalyzer.cc b/PhysicsTools/PatExamples/bin/PatBasicFWLiteJetAnalyzer.cc
index 3bfebf2edff74..5595aac923dce 100644
--- a/PhysicsTools/PatExamples/bin/PatBasicFWLiteJetAnalyzer.cc
+++ b/PhysicsTools/PatExamples/bin/PatBasicFWLiteJetAnalyzer.cc
@@ -39,7 +39,7 @@ int main(int argc, char* argv[]) {
}
// get the python configuration
- ProcessDescImpl builder(argv[1]);
+ ProcessDescImpl builder(argv[1], true);
const edm::ParameterSet& fwliteParameters =
builder.processDesc()->getProcessPSet()->getParameter("FWLiteParams");
diff --git a/PhysicsTools/PatExamples/bin/PatBasicFWLiteJetAnalyzer_Selector.cc b/PhysicsTools/PatExamples/bin/PatBasicFWLiteJetAnalyzer_Selector.cc
index b6755540d4adb..8e3c9c67098df 100644
--- a/PhysicsTools/PatExamples/bin/PatBasicFWLiteJetAnalyzer_Selector.cc
+++ b/PhysicsTools/PatExamples/bin/PatBasicFWLiteJetAnalyzer_Selector.cc
@@ -227,7 +227,7 @@ int main(int argc, char* argv[]) {
cout << "Getting parameters" << endl;
// Get the python configuration
- ProcessDescImpl builder(argv[1]);
+ ProcessDescImpl builder(argv[1], true);
std::shared_ptr b = builder.processDesc();
std::shared_ptr parameters = b->getProcessPSet();
parameters->registerIt();
diff --git a/PhysicsTools/PatExamples/bin/PatCleaningExercise.cc b/PhysicsTools/PatExamples/bin/PatCleaningExercise.cc
index 9e4524c1626e6..c6e73eb9f8aee 100644
--- a/PhysicsTools/PatExamples/bin/PatCleaningExercise.cc
+++ b/PhysicsTools/PatExamples/bin/PatCleaningExercise.cc
@@ -39,7 +39,7 @@ int main(int argc, char* argv[]) {
}
// get the python configuration
- ProcessDescImpl builder(argv[1]);
+ ProcessDescImpl builder(argv[1], true);
const edm::ParameterSet& fwliteParameters =
builder.processDesc()->getProcessPSet()->getParameter("FWLiteParams");
diff --git a/PhysicsTools/SelectorUtils/bin/testSelection_wplusjets.C b/PhysicsTools/SelectorUtils/bin/testSelection_wplusjets.C
index 0cd0d27307c1a..5e0485eb2c06e 100644
--- a/PhysicsTools/SelectorUtils/bin/testSelection_wplusjets.C
+++ b/PhysicsTools/SelectorUtils/bin/testSelection_wplusjets.C
@@ -35,7 +35,7 @@ int main(int argc, char** argv) {
}
// Get the python configuration
- ProcessDescImpl builder(argv[1]);
+ ProcessDescImpl builder(argv[1], true);
edm::ParameterSet const& shyftParameters =
builder.processDesc()->getProcessPSet()->getParameter("wplusjetsAnalysis");
edm::ParameterSet const& inputs = builder.processDesc()->getProcessPSet()->getParameter("inputs");