Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit d80d1d4f authored by Nick Desaulniers's avatar Nick Desaulniers Committed by android-build-merger
Browse files

Merge "[hardware][interfaces][vehicle] fix -Wdangling-gsl in test" am: 880ee395

am: e126b55e

Change-Id: Id124194c0bf8e4759b140d631dc2938bcf129168
parents d51753b4 e126b55e
Loading
Loading
Loading
Loading
+3 −3
Original line number Diff line number Diff line
@@ -57,11 +57,11 @@ public:
};

TEST_F(VehicleObjectPoolTest, valuePoolBasicCorrectness) {
    void* raw = valuePool->obtain(VehiclePropertyType::INT32).get();
    auto value = valuePool->obtain(VehiclePropertyType::INT32);
    // At this point, v1 should be recycled and the only object in the pool.
    ASSERT_EQ(raw, valuePool->obtain(VehiclePropertyType::INT32).get());
    ASSERT_EQ(value.get(), valuePool->obtain(VehiclePropertyType::INT32).get());
    // Obtaining value of another type - should return a new object
    ASSERT_NE(raw, valuePool->obtain(VehiclePropertyType::FLOAT).get());
    ASSERT_NE(value.get(), valuePool->obtain(VehiclePropertyType::FLOAT).get());

    ASSERT_EQ(3u, stats->Obtained);
    ASSERT_EQ(2u, stats->Created);