Skip to content
Snippets Groups Projects
Commit dbdd0728 authored by Daniel Hornung's avatar Daniel Hornung
Browse files

ENH: Value::IsNull is const

parent 51f202ec
No related branches found
No related tags found
1 merge request!12F consolidation
Pipeline #12312 passed
Pipeline: caosdb-cppinttest

#12313

    ......@@ -122,7 +122,7 @@ public:
    LIST_VALUE_CONSTRUCTOR(char *, set_string_value)
    LIST_VALUE_CONSTRUCTOR(bool, set_boolean_value)
    [[nodiscard]] inline auto IsNull() -> bool {
    [[nodiscard]] inline auto IsNull() const noexcept -> bool {
    return this->wrapped->value_case() == ValueCase::VALUE_NOT_SET;
    }
    ......
    ......@@ -65,6 +65,11 @@ TEST(test_value, test_string) {
    EXPECT_FALSE(empty_string.IsInteger());
    EXPECT_EQ(empty_string.AsString(), "");
    // Test inequality
    Value string1("1");
    Value int1(1);
    EXPECT_FALSE(string1 == int1);
    }
    TEST(test_value, test_double) {
    ......
    0% Loading or .
    You are about to add 0 people to the discussion. Proceed with caution.
    Finish editing this message first!
    Please register or to comment