File tree Expand file tree Collapse file tree 2 files changed +4
-4
lines changed
clickhouse_sqlalchemy/types Expand file tree Collapse file tree 2 files changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -52,7 +52,7 @@ class Nullable(ClickHouseTypeEngine):
52
52
__visit_name__ = 'nullable'
53
53
54
54
def __init__ (self , nested_type ):
55
- self .nested_type = nested_type
55
+ self .nested_type = to_instance ( nested_type )
56
56
super (Nullable , self ).__init__ ()
57
57
58
58
@@ -64,7 +64,7 @@ class LowCardinality(ClickHouseTypeEngine):
64
64
__visit_name__ = 'lowcardinality'
65
65
66
66
def __init__ (self , nested_type ):
67
- self .nested_type = nested_type
67
+ self .nested_type = to_instance ( nested_type )
68
68
super (LowCardinality , self ).__init__ ()
69
69
70
70
Original file line number Diff line number Diff line change @@ -62,7 +62,7 @@ def test_nullable(self):
62
62
63
63
self .assertIsInstance (col ['type' ], types .Nullable )
64
64
self .assertTrue (col ['nullable' ])
65
- self .assertEqual (col ['type' ].nested_type , types .Int32 )
65
+ self .assertIsInstance (col ['type' ].nested_type , types .Int32 )
66
66
67
67
def test_not_null (self ):
68
68
metadata = self .metadata ()
@@ -84,7 +84,7 @@ def test_low_cardinality(self):
84
84
)[0 ]['type' ]
85
85
86
86
self .assertIsInstance (coltype , types .LowCardinality )
87
- self .assertEqual (coltype .nested_type , types .String )
87
+ self .assertIsInstance (coltype .nested_type , types .String )
88
88
89
89
def test_tuple (self ):
90
90
coltype = self ._type_round_trip (
You can’t perform that action at this time.
0 commit comments