Skip to content
This repository was archived by the owner on May 17, 2024. It is now read-only.

Commit e0aafc0

Browse files
author
Sergey Vasilyev
committed
Skip JSON/JSONB cross-db tests when the db does not have this type
1 parent 746b72e commit e0aafc0

File tree

1 file changed

+10
-9
lines changed

1 file changed

+10
-9
lines changed

tests/test_database_types.py

Lines changed: 10 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -526,16 +526,17 @@ def get_test_db_pairs():
526526
for source_db, source_type_categories, target_db, target_type_categories in get_test_db_pairs():
527527
for type_category, source_types in source_type_categories.items(): # int, datetime, ..
528528
for source_type in source_types:
529-
for target_type in target_type_categories[type_category]:
530-
type_pairs.append(
531-
(
532-
source_db,
533-
target_db,
534-
source_type,
535-
target_type,
536-
type_category,
529+
if type_category in target_type_categories: # only cross-compatible types
530+
for target_type in target_type_categories[type_category]:
531+
type_pairs.append(
532+
(
533+
source_db,
534+
target_db,
535+
source_type,
536+
target_type,
537+
type_category,
538+
)
537539
)
538-
)
539540

540541

541542
def sanitize(name):

0 commit comments

Comments
 (0)