7#include "flutter/shell/platform/darwin/common/availability_version_check.h"
9#include "gtest/gtest.h"
11TEST(AvailabilityVersionCheck, CanDecodeSystemPlist) {
13 ASSERT_TRUE(maybe_product_version.has_value());
14 if (maybe_product_version.has_value()) {
15 auto product_version = maybe_product_version.value();
16 ASSERT_GT(product_version, std::make_tuple(0, 0, 0));
23 return ((major & 0xffff) << 16) | ((minor & 0xff) << 8) | (subminor & 0xff);
26TEST(AvailabilityVersionCheck, CanParseAndCompareVersions) {
27 auto rhs_version = std::make_tuple(17, 2, 0);
static uint32_t ConstructVersion(uint32_t major, uint32_t minor, uint32_t subminor)
TEST(AvailabilityVersionCheck, CanDecodeSystemPlist)
bool IsEncodedVersionLessThanOrSame(uint32_t encoded_lhs, ProductVersion rhs)
std::optional< ProductVersion > ProductVersionFromSystemVersionPList()