1d3335dfaSMatt Spinler #include <filesystem> 2d3335dfaSMatt Spinler #include <memory> 3d3335dfaSMatt Spinler #include <vector> 4d3335dfaSMatt Spinler 5d3335dfaSMatt Spinler #include <gtest/gtest.h> 6d3335dfaSMatt Spinler 7d3335dfaSMatt Spinler /** 8d3335dfaSMatt Spinler * @brief Tells the factory which PEL to create 9d3335dfaSMatt Spinler */ 10d3335dfaSMatt Spinler enum class TestPelType 11d3335dfaSMatt Spinler { 12d3335dfaSMatt Spinler pelSimple, 13*03c1d915SMatt Spinler privateHeaderSimple, 14*03c1d915SMatt Spinler userHeaderSimple 15d3335dfaSMatt Spinler }; 16d3335dfaSMatt Spinler 17d3335dfaSMatt Spinler /** 18d3335dfaSMatt Spinler * @brief PEL data factory, for testing 19d3335dfaSMatt Spinler * 20d3335dfaSMatt Spinler * @param[in] type - the type of data to create 21d3335dfaSMatt Spinler * 22d3335dfaSMatt Spinler * @return std::unique_ptr<std::vector<uint8_t>> - the PEL data 23d3335dfaSMatt Spinler */ 24d3335dfaSMatt Spinler std::unique_ptr<std::vector<uint8_t>> pelDataFactory(TestPelType type); 25d3335dfaSMatt Spinler 26d3335dfaSMatt Spinler /** 27d3335dfaSMatt Spinler * @brief Helper function to read raw PEL data from a file 28d3335dfaSMatt Spinler * 29d3335dfaSMatt Spinler * @param[in] path - the path to read 30d3335dfaSMatt Spinler * 31d3335dfaSMatt Spinler * @return std::unique_ptr<std::vector<uint8_t>> - the data from the file 32d3335dfaSMatt Spinler */ 33d3335dfaSMatt Spinler std::unique_ptr<std::vector<uint8_t>> 34d3335dfaSMatt Spinler readPELFile(const std::filesystem::path& path); 35