Blender V5.3
blender::bke::idprop::tests Namespace Reference

Classes

class  IDPropertySerializeTest

Functions

static void check_container_value (ArrayValue *value)
static void check_object_attribute (const DictionaryValue::Lookup &lookup, const std::string expected_key, const std::string expected_value)
static void check_object_attribute (const DictionaryValue::Lookup &lookup, const std::string expected_key, const int32_t expected_value)
static void check_object_attribute (const DictionaryValue::Lookup &lookup, const std::string expected_key, const float expected_value)
static void check_object_attribute (const DictionaryValue::Lookup &lookup, const std::string expected_key, const double expected_value)
static void test_string_to_value (const StringRefNull prop_name, const StringRefNull prop_content)
 TEST_F (IDPropertySerializeTest, convert_idp_string_to_value)
static void test_int_to_value (const StringRefNull prop_name, int32_t prop_content)
 TEST_F (IDPropertySerializeTest, convert_idp_int_to_value)
static void test_float_to_value (const StringRefNull prop_name, float prop_content)
 TEST_F (IDPropertySerializeTest, convert_idp_float_to_value)
static void test_double_to_value (const StringRefNull prop_name, double prop_content)
 TEST_F (IDPropertySerializeTest, convert_idp_double_to_value)
template<typename PrimitiveType, typename ValueType>
static void test_array_to_value (const StringRefNull prop_name, Vector< PrimitiveType > prop_content)
 TEST_F (IDPropertySerializeTest, convert_idp_int_array_to_value)
 TEST_F (IDPropertySerializeTest, convert_idp_float_array_to_value)
 TEST_F (IDPropertySerializeTest, convert_idp_double_array_to_value)
static std::unique_ptr< Value > parse_json (StringRef input)
static std::string to_json (const Value &value)
static void test_idprop (const IDProperty *id_property, StringRef expected_name, StringRef expected_value)
static void test_idprop (const IDProperty *id_property, StringRef expected_name, int32_t expected_value)
static void test_idprop (const IDProperty *id_property, StringRef expected_name, float expected_value)
static void test_idprop (const IDProperty *id_property, StringRef expected_name, double expected_value)
static void test_idprop (const IDProperty *id_property, StringRef expected_name, const Span< int32_t > values)
static void test_idprop (const IDProperty *id_property, StringRef expected_name, const Span< float > values)
static void test_idprop (const IDProperty *id_property, StringRef expected_name, const Span< double > values)
template<typename Type>
static void test_convert_idprop_from_value (StringRef input, StringRef expected_name, Type expected_value)
 TEST_F (IDPropertySerializeTest, convert_idp_string_from_value)
 TEST_F (IDPropertySerializeTest, convert_idp_int_from_value)
 TEST_F (IDPropertySerializeTest, convert_idp_float_from_value)
 TEST_F (IDPropertySerializeTest, convert_idp_double_from_value)
 TEST_F (IDPropertySerializeTest, convert_idp_array_int_from_value)
 TEST_F (IDPropertySerializeTest, convert_idp_array_float_from_value)
 TEST_F (IDPropertySerializeTest, convert_idp_array_double_from_value)
 TEST_F (IDPropertySerializeTest, convert_idp_multiple_from_value)
 TEST_F (IDPropertySerializeTest, convert_idp_multiple_roundtrip)
 TEST_F (IDPropertySerializeTest, convert_idp_group_from_value)

Function Documentation

◆ check_container_value()

◆ check_object_attribute() [1/4]

void blender::bke::idprop::tests::check_object_attribute ( const DictionaryValue::Lookup & lookup,
const std::string expected_key,
const double expected_value )
static

◆ check_object_attribute() [2/4]

void blender::bke::idprop::tests::check_object_attribute ( const DictionaryValue::Lookup & lookup,
const std::string expected_key,
const float expected_value )
static

◆ check_object_attribute() [3/4]

void blender::bke::idprop::tests::check_object_attribute ( const DictionaryValue::Lookup & lookup,
const std::string expected_key,
const int32_t expected_value )
static

◆ check_object_attribute() [4/4]

void blender::bke::idprop::tests::check_object_attribute ( const DictionaryValue::Lookup & lookup,
const std::string expected_key,
const std::string expected_value )
static

◆ parse_json()

std::unique_ptr< Value > blender::bke::idprop::tests::parse_json ( StringRef input)
static

Definition at line 202 of file idprop_serialize_test.cc.

References parse_json().

Referenced by parse_json(), test_convert_idprop_from_value(), TEST_F(), TEST_F(), and TEST_F().

◆ test_array_to_value()

◆ test_convert_idprop_from_value()

template<typename Type>
void blender::bke::idprop::tests::test_convert_idprop_from_value ( StringRef input,
StringRef expected_name,
Type expected_value )
static

◆ test_double_to_value()

◆ TEST_F() [1/17]

blender::bke::idprop::tests::TEST_F ( IDPropertySerializeTest ,
convert_idp_array_double_from_value  )

Definition at line 356 of file idprop_serialize_test.cc.

References test_convert_idprop_from_value(), and TEST_F().

◆ TEST_F() [2/17]

blender::bke::idprop::tests::TEST_F ( IDPropertySerializeTest ,
convert_idp_array_float_from_value  )

Definition at line 348 of file idprop_serialize_test.cc.

References test_convert_idprop_from_value(), and TEST_F().

◆ TEST_F() [3/17]

blender::bke::idprop::tests::TEST_F ( IDPropertySerializeTest ,
convert_idp_array_int_from_value  )

Definition at line 340 of file idprop_serialize_test.cc.

References test_convert_idprop_from_value(), and TEST_F().

◆ TEST_F() [4/17]

blender::bke::idprop::tests::TEST_F ( IDPropertySerializeTest ,
convert_idp_double_array_to_value  )

Definition at line 196 of file idprop_serialize_test.cc.

References test_array_to_value(), and TEST_F().

◆ TEST_F() [5/17]

blender::bke::idprop::tests::TEST_F ( IDPropertySerializeTest ,
convert_idp_double_from_value  )

Definition at line 334 of file idprop_serialize_test.cc.

References test_convert_idprop_from_value(), and TEST_F().

◆ TEST_F() [6/17]

blender::bke::idprop::tests::TEST_F ( IDPropertySerializeTest ,
convert_idp_double_to_value  )

Definition at line 153 of file idprop_serialize_test.cc.

References test_double_to_value(), and TEST_F().

◆ TEST_F() [7/17]

blender::bke::idprop::tests::TEST_F ( IDPropertySerializeTest ,
convert_idp_float_array_to_value  )

Definition at line 190 of file idprop_serialize_test.cc.

References test_array_to_value(), and TEST_F().

◆ TEST_F() [8/17]

blender::bke::idprop::tests::TEST_F ( IDPropertySerializeTest ,
convert_idp_float_from_value  )

Definition at line 328 of file idprop_serialize_test.cc.

References test_convert_idprop_from_value(), and TEST_F().

◆ TEST_F() [9/17]

blender::bke::idprop::tests::TEST_F ( IDPropertySerializeTest ,
convert_idp_float_to_value  )

Definition at line 132 of file idprop_serialize_test.cc.

References TEST_F(), and test_float_to_value().

◆ TEST_F() [10/17]

◆ TEST_F() [11/17]

blender::bke::idprop::tests::TEST_F ( IDPropertySerializeTest ,
convert_idp_int_array_to_value  )

Definition at line 184 of file idprop_serialize_test.cc.

References test_array_to_value(), and TEST_F().

◆ TEST_F() [12/17]

blender::bke::idprop::tests::TEST_F ( IDPropertySerializeTest ,
convert_idp_int_from_value  )

Definition at line 322 of file idprop_serialize_test.cc.

References test_convert_idprop_from_value(), and TEST_F().

◆ TEST_F() [13/17]

blender::bke::idprop::tests::TEST_F ( IDPropertySerializeTest ,
convert_idp_int_to_value  )

Definition at line 111 of file idprop_serialize_test.cc.

References TEST_F(), and test_int_to_value().

◆ TEST_F() [14/17]

◆ TEST_F() [15/17]

◆ TEST_F() [16/17]

blender::bke::idprop::tests::TEST_F ( IDPropertySerializeTest ,
convert_idp_string_from_value  )

Definition at line 314 of file idprop_serialize_test.cc.

References test_convert_idprop_from_value(), and TEST_F().

◆ TEST_F() [17/17]

blender::bke::idprop::tests::TEST_F ( IDPropertySerializeTest ,
convert_idp_string_to_value  )

◆ test_float_to_value()

◆ test_idprop() [1/7]

void blender::bke::idprop::tests::test_idprop ( const IDProperty * id_property,
StringRef expected_name,
const Span< double > values )
static

◆ test_idprop() [2/7]

◆ test_idprop() [3/7]

void blender::bke::idprop::tests::test_idprop ( const IDProperty * id_property,
StringRef expected_name,
const Span< int32_t > values )
static

◆ test_idprop() [4/7]

void blender::bke::idprop::tests::test_idprop ( const IDProperty * id_property,
StringRef expected_name,
double expected_value )
static

◆ test_idprop() [5/7]

void blender::bke::idprop::tests::test_idprop ( const IDProperty * id_property,
StringRef expected_name,
float expected_value )
static

◆ test_idprop() [6/7]

void blender::bke::idprop::tests::test_idprop ( const IDProperty * id_property,
StringRef expected_name,
int32_t expected_value )
static

◆ test_idprop() [7/7]

void blender::bke::idprop::tests::test_idprop ( const IDProperty * id_property,
StringRef expected_name,
StringRef expected_value )
static

◆ test_int_to_value()

◆ test_string_to_value()

◆ to_json()

std::string blender::bke::idprop::tests::to_json ( const Value & value)
static

Definition at line 210 of file idprop_serialize_test.cc.

References blender::gpu::shader::metadata::out, and to_json().

Referenced by TEST_F(), and to_json().