sandisland.cc
Go to the documentation of this file.
1 /*
2  * Copyright (C) 2018 Open Source Robotics Foundation
3  *
4  * Licensed under the Apache License, Version 2.0 (the "License");
5  * you may not use this file except in compliance with the License.
6  * You may obtain a copy of the License at
7  *
8  * http://www.apache.org/licenses/LICENSE-2.0
9  *
10  * Unless required by applicable law or agreed to in writing, software
11  * distributed under the License is distributed on an "AS IS" BASIS,
12  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13  * See the License for the specific language governing permissions and
14  * limitations under the License.
15  *
16 */
17 
18 #include <gtest/gtest.h>
19 #include "helpers.hh"
20 
23 class SandislandTest : public ::testing::Test
24 {
26  protected: static void SetUpTestCase();
27 };
28 
30 {
31 }
32 
35 TEST_F(SandislandTest, WamvExists)
36 {
37  EXPECT_TRUE(ModelExists("wamv"));
38 }
39 
42 TEST_F(SandislandTest, SandislandExists)
43 {
44  EXPECT_TRUE(ModelExists("sandisland"));
45 }
46 
49 TEST_F(SandislandTest, OceanExists)
50 {
51  EXPECT_TRUE(ModelExists("ocean"));
52 }
53 
55 int main(int argc, char **argv)
56 {
57  testing::InitGoogleTest(&argc, argv);
58  ros::init(argc, argv, "sandisland_test");
59  return RUN_ALL_TESTS();
60 }
Tests that the basic sandisland world with the wamv was loaded.
Definition: sandisland.cc:23
TEST_F(SandislandTest, WamvExists)
Tests that the wamv model exists.
Definition: sandisland.cc:35
ROSCPP_DECL void init(int &argc, char **argv, const std::string &name, uint32_t options=0)
int main(int argc, char **argv)
Definition: sandisland.cc:55
bool ModelExists(const std::string &_name, const ros::WallDuration _timeout=ros::WallDuration(5, 0))
Check whether a model exists on simulation.
Definition: helpers.hh:29
static void SetUpTestCase()
Initialize any members needed for the test cases.
Definition: sandisland.cc:29


vmrc_gazebo
Author(s): Brian Bingham , Carlos Aguero
autogenerated on Sun Feb 17 2019 03:14:16