Skip to content

Commit

Permalink
fix path concatencation
Browse files Browse the repository at this point in the history
Signed-off-by: ddengster <ed.fan@osrfoundation.org>
  • Loading branch information
ddengster committed Jun 23, 2021
1 parent 8cbade9 commit a475ee4
Showing 1 changed file with 12 additions and 7 deletions.
19 changes: 12 additions & 7 deletions test/integration/collada_world_exporter.cc
Original file line number Diff line number Diff line change
Expand Up @@ -77,9 +77,11 @@ TEST_F(ColladaWorldExporterFixture, ExportWorld)

TEST_F(ColladaWorldExporterFixture, ExportWorldFromFuelWithSubmesh)
{
std::string world_path =
ignition::common::joinPaths(PROJECT_SOURCE_PATH, "test","worlds");
ignition::common::setenv("IGN_GAZEBO_RESOURCE_PATH",
(std::string(PROJECT_SOURCE_PATH) + "/test/worlds:" +
std::string(PROJECT_SOURCE_PATH) + "/test/worlds/models").c_str());
(world_path + ":" +
ignition::common::joinPaths(world_path, "models")).c_str());

this->LoadWorld(common::joinPaths("test", "worlds",
"collada_world_exporter_submesh.sdf"));
Expand Down Expand Up @@ -112,19 +114,22 @@ TEST_F(ColladaWorldExporterFixture, ExportWorldFromFuelWithSubmesh)

TEST_F(ColladaWorldExporterFixture, ExportWorldMadeFromObj)
{
std::string world_path =
ignition::common::joinPaths(PROJECT_SOURCE_PATH, "test","worlds");
ignition::common::setenv("IGN_GAZEBO_RESOURCE_PATH",
(std::string(PROJECT_SOURCE_PATH) + "/test/worlds:" +
std::string(PROJECT_SOURCE_PATH) + "/test/worlds/models").c_str());
(world_path + ":" +
ignition::common::joinPaths(world_path, "models")).c_str());

this->LoadWorld(common::joinPaths("test", "worlds",
"office.sdf"));

const std::string outputPath = "./office_world";
const std::string outputPathTextures = "./office_world/materials/textures";
const std::string outputPathTextures =
common::joinPaths(outputPath, "materials", "textures");
const std::string outputPathTexture1 =
"./office_world/materials/textures/default.png";
common::joinPaths(outputPathTextures, "default.png");
const std::string outputPathTexture2 =
"./office_world/materials/textures/blue_linoleum.png";
common::joinPaths(outputPathTextures, "blue_linoleum.png");

// Cleanup
common::removeAll(outputPath);
Expand Down

0 comments on commit a475ee4

Please sign in to comment.