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

Commit d321c648 authored by Chris Manton's avatar Chris Manton Committed by Automerger Merge Worker
Browse files

Fix net_test_osi am: c757c89b20 am: 5ea1923be7 am: 137884f281 am: d3363286c5 am: 6ba5073c

Original change: https://googleplex-android-review.googlesource.com/c/platform/system/bt/+/15348171

Change-Id: I80828379ed6858a6fb45625766e41d8664d42642
parents d9b1981c 6ba5073c
Loading
Loading
Loading
Loading
+5 −1
Original line number Original line Diff line number Diff line
@@ -31,6 +31,7 @@ TEST_F(PropertiesTest, test_default_value) {
}
}


TEST_F(PropertiesTest, test_successfull_set_and_get_value) {
TEST_F(PropertiesTest, test_successfull_set_and_get_value) {
#if !defined(OS_GENERIC)
  char value[PROPERTY_VALUE_MAX] = "nothing_interesting";
  char value[PROPERTY_VALUE_MAX] = "nothing_interesting";
  int ret = osi_property_set("very.useful.set.test", value);
  int ret = osi_property_set("very.useful.set.test", value);
  ASSERT_EQ(0, ret);
  ASSERT_EQ(0, ret);
@@ -38,6 +39,7 @@ TEST_F(PropertiesTest, test_successfull_set_and_get_value) {
  char received[PROPERTY_VALUE_MAX];
  char received[PROPERTY_VALUE_MAX];
  osi_property_get("very.useful.set.test", received, NULL);
  osi_property_get("very.useful.set.test", received, NULL);
  ASSERT_STREQ(received, "nothing_interesting");
  ASSERT_STREQ(received, "nothing_interesting");
#endif
}
}


TEST_F(PropertiesTest, test_default_value_int32) {
TEST_F(PropertiesTest, test_default_value_int32) {
@@ -47,10 +49,12 @@ TEST_F(PropertiesTest, test_default_value_int32) {
}
}


TEST_F(PropertiesTest, test_successfull_set_and_get_value_int32) {
TEST_F(PropertiesTest, test_successfull_set_and_get_value_int32) {
#if !defined(OS_GENERIC)
  char value[PROPERTY_VALUE_MAX] = "42";
  char value[PROPERTY_VALUE_MAX] = "42";
  int ret = osi_property_set("very.useful.set.test", value);
  int ret = osi_property_set("very.useful.set.test", value);
  ASSERT_EQ(0, ret);
  ASSERT_EQ(0, ret);


  int32_t received = osi_property_get_int32("very.useful.set.test", 84);
  int32_t received = osi_property_get_int32("very.useful.set.test", 84);
  ASSERT_EQ(received, 42);
  ASSERT_EQ(received, 42);
#endif
}
}
+1 −1

File changed.

Contains only whitespace changes.