preparations for object_generator (generating objects with attributes and constraints)
This commit is contained in:
@@ -25,8 +25,8 @@ TEST_CASE("Test copy and move column", "[column]") {
|
||||
"name",
|
||||
basic_type::type_varchar,
|
||||
2,
|
||||
std::make_shared<attribute>("author", basic_type::type_uint32, "books", attribute_options{constraints::FOREIGN_KEY}),
|
||||
{255, constraints::FOREIGN_KEY},
|
||||
std::make_shared<attribute>("author", basic_type::type_uint32, "books", attribute_options{constraints::ForeignKey}),
|
||||
{255, constraints::ForeignKey},
|
||||
null_option_type::NOT_NULL
|
||||
);
|
||||
REQUIRE(c.name() == "name");
|
||||
|
||||
@@ -37,7 +37,7 @@ TEST_CASE("Test field", "[field]") {
|
||||
REQUIRE(bool_val.has_value());
|
||||
REQUIRE(bool_val.value());
|
||||
|
||||
f = sql::field("name", utils::blob{ 7,8,6,5,4,3 }, utils::constraints::NONE, 0, 1);
|
||||
f = sql::field("name", utils::blob{ 7,8,6,5,4,3 }, utils::constraints::None, 0, 1);
|
||||
REQUIRE(f.index() == 1);
|
||||
REQUIRE(!f.is_null());
|
||||
REQUIRE(!f.is_integer());
|
||||
|
||||
Reference in New Issue
Block a user