#ifndef LCAMERA_DEV_TESTS_CATALOG_HELPERS_H #define LCAMERA_DEV_TESTS_CATALOG_HELPERS_H #include #include #include #include namespace lcamera_dev { namespace tests { inline CameraIdentityRecord profileToIdentityRecord( const test_fixtures::BakedCameraProfile& profile) { CameraIdentityRecord record; record.id = profile.libcameraId; record.model = profile.model; record.locationLabel = profile.location; return record; } inline std::vector bakedProfilesAsRecords( const char *machineTag) { std::vector records; for (std::size_t i = 0; i < test_fixtures::bakedCameraProfileCount; ++i) { const test_fixtures::BakedCameraProfile& profile = test_fixtures::bakedCameraProfiles[i]; if (std::string(profile.machineTag) != machineTag) { continue; } records.push_back(profileToIdentityRecord(profile)); } return records; } } // namespace tests } // namespace lcamera_dev #endif // LCAMERA_DEV_TESTS_CATALOG_HELPERS_H