Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
A
ApplicationCore
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package Registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
ChimeraTK Mirror
ApplicationCore
Commits
2fc3757c
Commit
2fc3757c
authored
3 years ago
by
Martin Killenberg
Browse files
Options
Downloads
Patches
Plain Diff
ScriptedInitialisationHandler: improved wording in exception
parent
279a7716
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
Modules/src/ScriptedInitialisationHandler.cc
+1
-1
1 addition, 1 deletion
Modules/src/ScriptedInitialisationHandler.cc
tests/executables_src/testScriptedInitialisationHandler.cc
+16
-0
16 additions, 0 deletions
tests/executables_src/testScriptedInitialisationHandler.cc
with
17 additions
and
1 deletion
Modules/src/ScriptedInitialisationHandler.cc
+
1
−
1
View file @
2fc3757c
...
...
@@ -47,7 +47,7 @@ namespace ChimeraTK {
}
_lastFailed
=
true
;
std
::
this_thread
::
sleep_for
(
std
::
chrono
::
seconds
(
_errorGracePeriod
));
throw
ChimeraTK
::
runtime_error
(
_deviceAlias
+
"
board
initialisation failed."
);
throw
ChimeraTK
::
runtime_error
(
_deviceAlias
+
" initialisation failed."
);
}
else
{
output
+=
_deviceAlias
+
" initialisation SUCCESS!"
;
...
...
This diff is collapsed.
Click to expand it.
tests/executables_src/testScriptedInitialisationHandler.cc
+
16
−
0
View file @
2fc3757c
...
...
@@ -127,3 +127,19 @@ BOOST_FIXTURE_TEST_CASE(testError, Fixture) {
(
void
)
std
::
filesystem
::
remove
(
"device1Init.success"
);
(
void
)
std
::
filesystem
::
remove
(
"continueDevice1Init"
);
}
BOOST_AUTO_TEST_CASE
(
testBoostException
)
{
BOOST_CHECK
(
false
);
std
::
filesystem
::
rename
(
"deviceInitScript1.bash"
,
"deviceInitScript1.bash.dontuse"
);
try
{
DMapSetter
dmapSetter
;
TestApp
testApp
{
"ScriptedInitApp"
};
TestFacility
testFacility
{
false
};
testFacility
.
runApplication
();
sleep
(
10
);
}
catch
(
ChimeraTK
::
logic_error
&
e
)
{
std
::
cout
<<
"I caught the exception!"
<<
std
::
endl
;
}
std
::
filesystem
::
rename
(
"deviceInitScript1.bash.dontuse"
,
"deviceInitScript1.bash"
);
}
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment