Summary
Add comprehensive tests for any_to_dbvalue_or_throw() and related field-binding helpers.
Mapper values cross the ORM boundary through std::any, so conversion behavior must remain predictable and portable.
Current behavior
The ORM compatibility layer supports conversion from:
- empty
std::any;
std::nullptr_t;
vix::db::DbValue;
- signed and unsigned integer types;
bool;
float;
double;
std::string;
std::string_view;
- C strings;
vix::db::Blob.
Unsupported types produce DBError.
These conversions are not covered by automated tests.
Expected behavior
Every documented input type must convert to the expected DbValue alternative without silent narrowing or lifetime errors.
Unsupported types must fail with a clear ORM diagnostic.
Scope
Suggested files
modules/orm/tests/dbvalue_conversion_test.cpp
modules/orm/include/vix/orm/db_compat.hpp
Acceptance criteria
Non-goals
This issue does not include:
- replacing
std::any;
- adding date and time conversions;
- adding enum conversions;
- changing
DbValue.
Suggested labels
scope:orm
type:ci
tests
good first issue
status:ready
Summary
Add comprehensive tests for
any_to_dbvalue_or_throw()and related field-binding helpers.Mapper values cross the ORM boundary through
std::any, so conversion behavior must remain predictable and portable.Current behavior
The ORM compatibility layer supports conversion from:
std::any;std::nullptr_t;vix::db::DbValue;bool;float;double;std::string;std::string_view;vix::db::Blob.Unsupported types produce
DBError.These conversions are not covered by automated tests.
Expected behavior
Every documented input type must convert to the expected
DbValuealternative without silent narrowing or lifetime errors.Unsupported types must fail with a clear ORM diagnostic.
Scope
std::any.std::nullptr_t.DbValue.bool.floatanddouble.std::string.std::string_view.const char*andchar*.Blob.field_to_dbvalue_or_throw().bind_field_values().Suggested files
modules/orm/tests/dbvalue_conversion_test.cppmodules/orm/include/vix/orm/db_compat.hppAcceptance criteria
vix::db::DBError.Non-goals
This issue does not include:
std::any;DbValue.Suggested labels
scope:ormtype:citestsgood first issuestatus:ready