@@ -258,9 +258,12 @@ def test_highlight_least(sample_data):
258258
259259 # Verify the correct intersection is highlighted
260260 actual_ids = [v ["intersection_id" ] for v in color_param ["value" ]]
261- assert len (actual_ids ) == 1 , f"Expected 1 highlighted intersection, got { len (actual_ids )} "
261+ assert len (actual_ids ) == 1 , (
262+ f"Expected 1 highlighted intersection, got { len (actual_ids )} "
263+ )
262264 assert actual_ids [0 ] == expected_min_id , (
263- f"Expected intersection { expected_min_id } (smallest), but got { actual_ids [0 ]} "
265+ f"Expected intersection { expected_min_id } (smallest), "
266+ f"but got { actual_ids [0 ]} "
264267 )
265268
266269 # Verify it's actually the minimum count
@@ -293,9 +296,12 @@ def test_highlight_greatest(sample_data):
293296
294297 # Verify the correct intersection is highlighted
295298 actual_ids = [v ["intersection_id" ] for v in color_param ["value" ]]
296- assert len (actual_ids ) == 1 , f"Expected 1 highlighted intersection, got { len (actual_ids )} "
299+ assert len (actual_ids ) == 1 , (
300+ f"Expected 1 highlighted intersection, got { len (actual_ids )} "
301+ )
297302 assert actual_ids [0 ] == expected_max_id , (
298- f"Expected intersection { expected_max_id } (largest), but got { actual_ids [0 ]} "
303+ f"Expected intersection { expected_max_id } (largest), "
304+ f"but got { actual_ids [0 ]} "
299305 )
300306
301307 # Verify it's actually the maximum count
@@ -327,9 +333,12 @@ def test_highlight_specific_index(sample_data):
327333
328334 # Verify the correct intersection is highlighted
329335 actual_ids = [v ["intersection_id" ] for v in color_param ["value" ]]
330- assert len (actual_ids ) == 1 , f"Expected 1 highlighted intersection, got { len (actual_ids )} "
336+ assert len (actual_ids ) == 1 , (
337+ f"Expected 1 highlighted intersection, got { len (actual_ids )} "
338+ )
331339 assert actual_ids [0 ] == expected_id , (
332- f"Expected intersection { expected_id } at index 0, but got { actual_ids [0 ]} "
340+ f"Expected intersection { expected_id } at index 0, "
341+ f"but got { actual_ids [0 ]} "
333342 )
334343
335344
@@ -357,7 +366,9 @@ def test_highlight_multiple_indices(sample_data):
357366
358367 # Verify the correct intersections are highlighted
359368 actual_ids = [v ["intersection_id" ] for v in color_param ["value" ]]
360- assert len (actual_ids ) == 3 , f"Expected 3 highlighted intersections, got { len (actual_ids )} "
369+ assert len (actual_ids ) == 3 , (
370+ f"Expected 3 highlighted intersections, got { len (actual_ids )} "
371+ )
361372 assert set (actual_ids ) == set (expected_ids ), (
362373 f"Expected intersections { expected_ids } , but got { actual_ids } "
363374 )
@@ -382,7 +393,9 @@ def test_highlight_none_default_hover(sample_data):
382393
383394def test_highlight_invalid_string (sample_data ):
384395 """Test that invalid string values for highlight raise ValueError."""
385- with pytest .raises (ValueError , match = "highlight string must be 'least' or 'greatest'" ):
396+ with pytest .raises (
397+ ValueError , match = "highlight string must be 'least' or 'greatest'"
398+ ):
386399 au .UpSetAltair (data = sample_data , sets = ["A" , "B" , "C" ], highlight = "invalid" )
387400
388401
@@ -402,7 +415,9 @@ def test_highlight_invalid_list(sample_data):
402415
403416def test_highlight_invalid_type (sample_data ):
404417 """Test that invalid types for highlight raise TypeError."""
405- with pytest .raises (TypeError , match = "highlight must be None, str, int, or list of int" ):
418+ with pytest .raises (
419+ TypeError , match = "highlight must be None, str, int, or list of int"
420+ ):
406421 au .UpSetAltair (data = sample_data , sets = ["A" , "B" , "C" ], highlight = 1.5 )
407422
408423
0 commit comments