| 44 | using namespace pdal; |
| 45 | |
| 46 | TEST(PipelineManagerTest, basic) |
| 47 | { |
| 48 | std::string outfile = Support::temppath("temp.las"); |
| 49 | FileUtils::deleteFile(outfile); |
| 50 | |
| 51 | PipelineManager mgr; |
| 52 | |
| 53 | Options optsR; |
| 54 | optsR.add("filename", Support::datapath("las/1.2-with-color.las")); |
| 55 | Stage& reader = mgr.addReader("readers.las"); |
| 56 | reader.setOptions(optsR); |
| 57 | |
| 58 | Options optsW; |
| 59 | optsW.add("filename", outfile); |
| 60 | Stage& writer = mgr.addWriter("writers.las"); |
| 61 | writer.setInput(reader); |
| 62 | writer.setOptions(optsW); |
| 63 | |
| 64 | point_count_t np = mgr.execute(); |
| 65 | EXPECT_EQ(np, 1065U); |
| 66 | |
| 67 | EXPECT_TRUE(!std::ifstream(outfile).fail()); |
| 68 | FileUtils::deleteFile(outfile); |
| 69 | } |
| 70 | |
| 71 | // Make sure that when we add an option at the command line, it overrides |
| 72 | // a pipeline option. |
nothing calls this directly
no test coverage detected