mirror of
https://github.com/Infinidat/infi.clickhouse_orm.git
synced 2024-11-24 18:03:42 +03:00
Support for function-based DEFAULT values, not only literals #36
This commit is contained in:
parent
ffeed4a6a4
commit
4ffc27100d
|
@ -4,7 +4,7 @@ import datetime
|
|||
import pytz
|
||||
|
||||
from infi.clickhouse_orm.database import Database
|
||||
from infi.clickhouse_orm.models import Model
|
||||
from infi.clickhouse_orm.models import Model, NO_VALUE
|
||||
from infi.clickhouse_orm.fields import *
|
||||
from infi.clickhouse_orm.engines import *
|
||||
from infi.clickhouse_orm.utils import parse_tsv
|
||||
|
@ -67,7 +67,7 @@ class CompressedFieldsTestCase(unittest.TestCase):
|
|||
"int64_field": 100,
|
||||
"float_field": 7.0,
|
||||
"datetime_field": datetime.datetime(1970, 1, 1, 0, 0, 0, tzinfo=pytz.utc),
|
||||
"alias_field": 0.0,
|
||||
"alias_field": NO_VALUE,
|
||||
'string_field': 'dozo',
|
||||
'nullable_field': None,
|
||||
'uint64_field': 0,
|
||||
|
|
|
@ -65,7 +65,7 @@ class ModelTestCase(unittest.TestCase):
|
|||
"int_field": 100,
|
||||
"float_field": 7.0,
|
||||
"datetime_field": datetime.datetime(1970, 1, 1, 0, 0, 0, tzinfo=pytz.utc),
|
||||
"alias_field": 0.0,
|
||||
"alias_field": NO_VALUE,
|
||||
"str_field": "dozo",
|
||||
"default_func": NO_VALUE
|
||||
})
|
||||
|
|
Loading…
Reference in New Issue
Block a user