From ee25abee7a9c4d22148c64f257bb35fd816e8496 Mon Sep 17 00:00:00 2001 From: Alexander Kreft <akreft@trineo.org> Date: Wed, 25 Aug 2021 12:21:22 +0000 Subject: [PATCH] DRAFT: Test update entity --- test/runtests.jl | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) diff --git a/test/runtests.jl b/test/runtests.jl index 7c351fc..e8c461b 100644 --- a/test/runtests.jl +++ b/test/runtests.jl @@ -149,4 +149,23 @@ end end + @testset "Test entity update" begin + + resset = execute_query("FIND TestEnt") + ent_with_name = execute_query("FIND TestEnt") + prop = CaosDB.Entity.create_property(name = "TestProperty", value = "12345") + CaosDB.Entity.set_datatype(prop, "INTEGER") + CaosDB.Entity.append_properties(ent_with_name[1], [prop]) + + single_insert_transaction = create_transaction() + add_update_entity(single_insert_transaction , ent_with_name[1]) + execute(single_insert_transaction) + results = get_results(single_insert_transaction ) + + @test length(results) == 1 + @test has_errors(results[1]) == false + @test get_id(results[1]) != "" + + end + end -- GitLab