Skip to content

Commit 0082ab5

Browse files
committed
Organizing unit tests. Typo fixes.
1 parent 04c8a5a commit 0082ab5

19 files changed

+155
-225
lines changed

tests/data/error_collision_geometry_not_exist.urdf

Lines changed: 0 additions & 37 deletions
This file was deleted.

tests/data/error_material_same_name.urdf renamed to tests/data/error_dupilcate_material_names.urdf

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,4 @@
1-
<robot name="error_check">
2-
<material name="red">
3-
<color rgba="1.0 0.0 0.0 1"/>
4-
</material>
1+
<robot name="same_material_name">
52
<material name="green">
63
<color rgba="0.0 1.0 0.0 1"/>
74
</material>
Lines changed: 40 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,40 @@
1+
<robot name="duplicate_joint_names">
2+
<link name="BaseLink">
3+
<visual>
4+
<origin rpy="0 0 0" xyz="-2 0 0.5"/>
5+
<geometry>
6+
<box size="1 1 1"/>
7+
</geometry>
8+
</visual>
9+
</link>
10+
11+
<link name="link2">
12+
<visual>
13+
<origin rpy="0 0 0" xyz="0 0 0.5"/>
14+
<geometry>
15+
<box size="1 1 1"/>
16+
</geometry>
17+
</visual>
18+
</link>
19+
20+
<link name="link3">
21+
<visual>
22+
<origin rpy="0 0 0" xyz="2 0 0.5"/>
23+
<geometry>
24+
<box size="1 1 1"/>
25+
</geometry>
26+
</visual>
27+
</link>
28+
29+
<joint name="JointA" type="fixed">
30+
<parent link="BaseLink"/>
31+
<child link="link2" />
32+
</joint>
33+
34+
<!-- This is a deliberate mistake. -->
35+
<!-- The joint name is the same as the existing joint name. -->
36+
<joint name="JointA" type="fixed">
37+
<parent link="link2"/>
38+
<child link="link3" />
39+
</joint>
40+
</robot>
Lines changed: 1 addition & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -1,21 +1,10 @@
1-
<robot name="error_check">
2-
<material name="red">
3-
<color rgba="1.0 0.0 0.0 1"/>
4-
</material>
5-
<material name="green">
6-
<color rgba="0.0 1.0 0.0 1"/>
7-
</material>
8-
<material name="blue">
9-
<color rgba="0.0 0.0 1.0 1"/>
10-
</material>
11-
1+
<robot name="duplicate_link_names">
122
<link name="BaseLink">
133
<visual>
144
<origin rpy="0 0 0" xyz="-2 0 0.5"/>
155
<geometry>
166
<box size="1 1 1"/>
177
</geometry>
18-
<material name="red"/>
198
</visual>
209
</link>
2110

@@ -25,7 +14,6 @@
2514
<geometry>
2615
<sphere radius="0.5"/>
2716
</geometry>
28-
<material name="green"/>
2917
</visual>
3018
</link>
3119

@@ -37,7 +25,6 @@
3725
<geometry>
3826
<cylinder radius="0.5" length="1"/>
3927
</geometry>
40-
<material name="blue"/>
4128
</visual>
4229
</link>
4330
</robot>

tests/data/error_joint_non_existent_child_link_name.urdf renamed to tests/data/error_incorrect_joint_child_link_name.urdf

Lines changed: 1 addition & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -1,21 +1,10 @@
1-
<robot name="error_check">
2-
<material name="red">
3-
<color rgba="1.0 0.0 0.0 1"/>
4-
</material>
5-
<material name="green">
6-
<color rgba="0.0 1.0 0.0 1"/>
7-
</material>
8-
<material name="blue">
9-
<color rgba="0.0 0.0 1.0 1"/>
10-
</material>
11-
1+
<robot name="incorrect_joint_child_link_name">
122
<link name="BaseLink">
133
<visual>
144
<origin rpy="0 0 0" xyz="-2 0 0.5"/>
155
<geometry>
166
<box size="1 1 1"/>
177
</geometry>
18-
<material name="red"/>
198
</visual>
209
</link>
2110

@@ -25,7 +14,6 @@
2514
<geometry>
2615
<sphere radius="0.5"/>
2716
</geometry>
28-
<material name="green"/>
2917
</visual>
3018
</link>
3119

tests/data/error_joint_non_existent_parent_link_name.urdf renamed to tests/data/error_incorrect_joint_parent_link_name.urdf

Lines changed: 1 addition & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -1,21 +1,10 @@
1-
<robot name="error_check">
2-
<material name="red">
3-
<color rgba="1.0 0.0 0.0 1"/>
4-
</material>
5-
<material name="green">
6-
<color rgba="0.0 1.0 0.0 1"/>
7-
</material>
8-
<material name="blue">
9-
<color rgba="0.0 0.0 1.0 1"/>
10-
</material>
11-
1+
<robot name="incorrect_joint_parent_link_name">
122
<link name="BaseLink">
133
<visual>
144
<origin rpy="0 0 0" xyz="-2 0 0.5"/>
155
<geometry>
166
<box size="1 1 1"/>
177
</geometry>
18-
<material name="red"/>
198
</visual>
209
</link>
2110

@@ -25,7 +14,6 @@
2514
<geometry>
2615
<sphere radius="0.5"/>
2716
</geometry>
28-
<material name="green"/>
2917
</visual>
3018
</link>
3119

tests/data/error_joint_incorrect_type.urdf renamed to tests/data/error_incorrect_joint_type.urdf

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
<robot name="error_check">
1+
<robot name="incorrect_joint_type">
22
<link name="BaseLink">
33
<visual>
44
<origin rpy="0 0 0" xyz="-2 0 0.5"/>
Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
<robot name="incorrect_visual_geometry_name">
2+
<link name="BaseLink">
3+
<visual>
4+
<!-- This is a deliberate mistake. -->
5+
<!-- The specified geometry type is invalid. -->
6+
<geometry>
7+
<foo size="1 1 1"/>
8+
</geometry>
9+
<material name="green"/>
10+
</visual>
11+
</link>
12+
</robot>

tests/data/error_invalid_geometry_type.urdf

Lines changed: 0 additions & 30 deletions
This file was deleted.
Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
<robot name="invalid_material_name">
2+
<material name="red">
3+
<color rgba="1.0 0.0 0.0 1"/>
4+
</material>
5+
6+
<link name="BaseLink">
7+
<visual>
8+
<geometry>
9+
<sphere radius="0.5"/>
10+
</geometry>
11+
<!-- This is a deliberate mistake. -->
12+
<!-- The specified material does not exist. -->
13+
<material name="green"/>
14+
</visual>
15+
</link>
16+
</robot>

0 commit comments

Comments
 (0)