Skip to content
Snippets Groups Projects
Commit 01740deb authored by Alexander Kreft's avatar Alexander Kreft
Browse files

STY: Code formatting

parent 6bca4319
No related branches found
No related tags found
1 merge request!4F full ak
Pipeline #12589 failed
......@@ -140,9 +140,9 @@ end
@testset "Test entity insertion" begin
ent_with_name = CaosDB.Entity.create_recordtype("TestEnt")
single_insert_transaction = create_transaction()
add_insert_entity(single_insert_transaction , ent_with_name)
add_insert_entity(single_insert_transaction, ent_with_name)
execute(single_insert_transaction)
results = get_results(single_insert_transaction )
results = get_results(single_insert_transaction)
@test length(results) == 1
@test has_errors(results[1]) == false
@test get_id(results[1]) != ""
......@@ -150,25 +150,30 @@ end
end
@testset "Test entity update" begin
ent_with_name = execute_query("FIND TestEnt")
prop = CaosDB.Entity.create_property_entity(name = "TestProperty", datatype = "TEXT", unit = "cm",
is_reference = false, is_list = false)
prop = CaosDB.Entity.create_property_entity(
name = "TestProperty",
datatype = "TEXT",
unit = "cm",
is_reference = false,
is_list = false,
)
single_insert_transaction1 = create_transaction()
add_insert_entity(single_insert_transaction1, prop)
execute(single_insert_transaction1)
results = get_results(single_insert_transaction1 )
prop2 = CaosDB.Entity.create_property(id=get_id(results[1]))
results = get_results(single_insert_transaction1)
prop2 = CaosDB.Entity.create_property(id = get_id(results[1]))
CaosDB.Entity.append_property(ent_with_name[1], prop2)
single_insert_transaction = create_transaction()
add_update_entity(single_insert_transaction , ent_with_name[1])
add_update_entity(single_insert_transaction, ent_with_name[1])
execute(single_insert_transaction)
results = get_results(single_insert_transaction )
results = get_results(single_insert_transaction)
@test length(results) == 1
@test has_errors(results[1]) == false
@test get_id(results[1]) != ""
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment