Main Page
Related Pages
Modules
Namespaces
Classes
Files
Examples
File List
File Members
messagefacility
messagefacility
Utilities
catch_main.cc
Go to the documentation of this file.
1
// vim: set sw=2 expandtab :
2
#define CATCH_CONFIG_RUNNER
3
#include "catch2/catch.hpp"
4
5
#include "
cetlib/filepath_maker.h
"
6
#include "
fhiclcpp/ParameterSet.h
"
7
#include "
messagefacility/MessageLogger/MessageLogger.h
"
8
9
#include <string>
10
11
using namespace
std
;
12
using namespace
std::string_literals
;
13
14
int
15
main
(
int
argc,
char
**
argv
)
16
{
17
Catch::Session
session
;
18
std::string
fhiclConfigFileName;
19
using namespace
Catch::clara;
20
// Our non-option argument, being non-optional, should be first.
21
auto
cli
= Arg(fhiclConfigFileName,
"config.fcl"
)(
"<fhicl-config-file>"
) |
22
session.cli();
23
24
session.cli(
cli
);
25
26
int
result
= session.applyCommandLine(argc, argv);
27
if
(result == 0) {
28
mf::SetIteration
(
"JobSetup"
s
);
29
cet::filepath_maker
fpm;
30
auto
const
msg_ps =
fhicl::ParameterSet::make
(fhiclConfigFileName, fpm);
31
mf::StartMessageFacility
(msg_ps);
32
result = session.run();
33
}
34
return
(result < 0xff ? result : 0xff);
35
}
mf::SetIteration
void SetIteration(string const &val)
Definition:
MessageLogger.cc:574
result
static QCString result
Definition:
fortranscanner.cpp:56614
string
std::string string
Definition:
nybbler.cc:12
fhicl::ParameterSet::make
static ParameterSet make(intermediate_table const &tbl)
Definition:
ParameterSet.cc:68
std
STL namespace.
freeze_graph.argv
argv
Definition:
freeze_graph.py:218
MessageLogger.h
ParameterSet.h
string_literals
wirecell.gen.main.cli
def cli(ctx)
Definition:
main.py:7
cet::filepath_maker
Definition:
filepath_maker.h:42
mf::StartMessageFacility
void StartMessageFacility(fhicl::ParameterSet const &pset, string const &applicationName)
Definition:
MessageLogger.cc:460
filepath_maker.h
wirecell.util.wires.db.session
def session(dburl="sqlite:///:memory:")
Definition:
db.py:754
main
int main(int argc, char **argv)
Definition:
catch_main.cc:15
s
static QCString * s
Definition:
config.cpp:1042
Generated by
1.8.11