Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
Stack Of Tasks
sot-pattern-generator
Commits
f75590ee
Commit
f75590ee
authored
Aug 26, 2020
by
Olivier Stasse
Browse files
[tests] Update tests.
parent
962714f8
Pipeline
#10881
failed with stage
in 2 minutes and 48 seconds
Changes
2
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
tests/CMakeLists.txt
View file @
f75590ee
...
...
@@ -7,5 +7,22 @@ ADD_DEFINITIONS(-DDEBUG=2)
ADD_UNIT_TEST
(
main_test main.cc
)
TARGET_LINK_LIBRARIES
(
main_test
jrl-walkgen::jrl-walkgen
sot-core::sot-core
next-step
next-step-pg-sot
step-checker
step-computer-joystick
step-observer
step-queue
step-time-line
which-foot-upper
pg
pg-manager
)
SET
(
urdfpath
${
TALOS_DATA_PREFIX
}
/share/talos_data/urdf/talos_full_v2.urdf
)
TARGET_COMPILE_DEFINITIONS
(
main_test PUBLIC
URDF_FULL_PATH=
"
${
urdfpath
}
"
)
tests/main.cc
View file @
f75590ee
...
...
@@ -105,26 +105,10 @@ int main(int, char**) {
using
namespace
std
;
dynamicgraph
::
sot
::
PatternGenerator
aPG
;
// Get environment variable CMAKE_PREFIX_PATH
const
string
s_cmake_prefix_path
=
getenv
(
"CMAKE_PREFIX_PATH"
);
// Read the various paths
vector
<
string
>
paths
;
boost
::
split
(
paths
,
s_cmake_prefix_path
,
boost
::
is_any_of
(
":;"
));
// Search talos_reduced_wpg.urdf
string
filename
=
""
;
for
(
auto
test_path
:
paths
)
{
filename
=
test_path
+
string
(
"/share/talos_data/urdf/talos_full_v2.urdf"
);
if
(
boost
::
filesystem
::
exists
(
filename
))
break
;
}
// If not found fails
if
(
filename
.
size
()
==
0
)
string
filename
(
URDF_FULL_PATH
);
if
(
!
boost
::
filesystem
::
exists
(
filename
))
{
cerr
<<
"Unable to find talos_reduced_wpg.urdf"
<<
endl
;
exit
(
-
1
);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment