@@ -140,23 +140,23 @@ def test_getting_and_deleting_cheuk(schema_test_db):
140140 assert "cheuk" not in globals ()
141141 assert "cheuk" not in locals ()
142142 client .connect (db = db_name )
143-
143+
144144 # Set up: Create test data first
145145 Country = test_schema .object .get ("Country" )
146146 Address = test_schema .object .get ("Address" )
147147 Employee = test_schema .object .get ("Employee" )
148148 Role = test_schema .object .get ("Role" )
149149 Team = test_schema .object .get ("Team" )
150-
150+
151151 uk = Country ()
152152 uk .name = "UK Test 1"
153153 uk .perimeter = []
154-
154+
155155 home = Address ()
156156 home .street = "123 Abc Street"
157157 home .country = uk
158158 home .postal_code = "A12 345"
159-
159+
160160 cheuk_setup = Employee ()
161161 cheuk_setup .permisstion = {Role .Admin , Role .Read }
162162 cheuk_setup .address_of = home
@@ -167,9 +167,9 @@ def test_getting_and_deleting_cheuk(schema_test_db):
167167 cheuk_setup .managed_by = cheuk_setup
168168 cheuk_setup .friend_of = {cheuk_setup }
169169 cheuk_setup .member_of = Team .IT
170-
170+
171171 client .insert_document ([cheuk_setup ], commit_msg = "Setup for test_getting_and_deleting_cheuk" )
172-
172+
173173 # Test: Load and verify
174174 new_schema = WOQLSchema ()
175175 new_schema .from_db (client )
@@ -188,14 +188,14 @@ def test_getting_and_deleting_cheuk(schema_test_db):
188188def test_insert_cheuk_again (schema_test_db ):
189189 db_name , client , test_schema = schema_test_db
190190 client .connect (db = db_name )
191-
191+
192192 # Set up: Create Country first
193193 Country = test_schema .object .get ("Country" )
194194 uk_setup = Country ()
195195 uk_setup .name = "UK Test 2"
196196 uk_setup .perimeter = []
197197 client .insert_document ([uk_setup ], commit_msg = "Setup country for test_insert_cheuk_again" )
198-
198+
199199 # Test: Load country and create employee
200200 new_schema = WOQLSchema ()
201201 new_schema .from_db (client )
@@ -243,7 +243,7 @@ def test_insert_cheuk_again(schema_test_db):
243243 found_country = False
244244 found_employee = False
245245 found_coordinate = False
246-
246+
247247 for item in result :
248248 if item .get ("@type" ) == "Country" and item .get ("name" ) == "UK Test 2" :
249249 assert item ["perimeter" ]
@@ -259,7 +259,7 @@ def test_insert_cheuk_again(schema_test_db):
259259 elif item .get ("@type" ) == "Coordinate" and item .get ("x" ) == - 0.7 :
260260 assert item ["y" ] == 51.3
261261 found_coordinate = True
262-
262+
263263 assert found_country , "UK Test 2 country not found"
264264 assert found_employee , "cheuk_test_2 employee not found"
265265 assert found_coordinate , "Coordinate not found"
@@ -268,27 +268,27 @@ def test_insert_cheuk_again(schema_test_db):
268268def test_get_data_version (schema_test_db ):
269269 db_name , client , test_schema = schema_test_db
270270 client .connect (db = db_name )
271-
271+
272272 # Set up: Create test employee for data version tests
273273 Country = test_schema .object .get ("Country" )
274274 Address = test_schema .object .get ("Address" )
275275 Employee = test_schema .object .get ("Employee" )
276276 Role = test_schema .object .get ("Role" )
277277 Team = test_schema .object .get ("Team" )
278278 Coordinate = test_schema .object .get ("Coordinate" )
279-
279+
280280 uk = Country ()
281281 uk .name = "UK Test 3"
282282 uk .perimeter = []
283-
283+
284284 home = Address ()
285285 home .street = "123 Abc Street"
286286 home .country = uk
287287 home .postal_code = "A12 345"
288-
288+
289289 location = Coordinate (x = 0.7 , y = 51.3 )
290290 uk .perimeter = [location ]
291-
291+
292292 cheuk = Employee ()
293293 cheuk .permisstion = {Role .Admin , Role .Read }
294294 cheuk .address_of = home
@@ -299,7 +299,7 @@ def test_get_data_version(schema_test_db):
299299 cheuk .friend_of = {cheuk }
300300 cheuk .member_of = Team .IT
301301 cheuk ._id = "cheuk_test_3"
302-
302+
303303 client .insert_document ([location , uk , cheuk ], commit_msg = "Setup for test_get_data_version" )
304304 result , version = client .get_all_branches (get_data_version = True )
305305 assert version
0 commit comments