@@ -1214,7 +1214,7 @@ def test_create_table_timestamp(con, temp_table):
12141214 reason = "Feature is not yet implemented: CREATE TEMPORARY TABLE" ,
12151215)
12161216def test_persist_expression_ref_count (backend , con , alltypes ):
1217- non_persisted_table = alltypes .mutate (test_column = "calculation" )
1217+ non_persisted_table = alltypes .mutate (test_column = ibis . literal ( "calculation" ) )
12181218 persisted_table = non_persisted_table .cache ()
12191219
12201220 op = non_persisted_table .op ()
@@ -1239,7 +1239,9 @@ def test_persist_expression_ref_count(backend, con, alltypes):
12391239 reason = "Feature is not yet implemented: CREATE TEMPORARY TABLE" ,
12401240)
12411241def test_persist_expression (backend , alltypes ):
1242- non_persisted_table = alltypes .mutate (test_column = "calculation" , other_calc = "xyz" )
1242+ non_persisted_table = alltypes .mutate (
1243+ test_column = ibis .literal ("calculation" ), other_calc = ibis .literal ("xyz" )
1244+ )
12431245 persisted_table = non_persisted_table .cache ()
12441246 backend .assert_frame_equal (
12451247 non_persisted_table .to_pandas (), persisted_table .to_pandas ()
@@ -1259,7 +1261,7 @@ def test_persist_expression(backend, alltypes):
12591261)
12601262def test_persist_expression_contextmanager (backend , alltypes ):
12611263 non_cached_table = alltypes .mutate (
1262- test_column = "calculation" , other_column = "big calc"
1264+ test_column = ibis . literal ( "calculation" ) , other_column = ibis . literal ( "big calc" )
12631265 )
12641266 with non_cached_table .cache () as cached_table :
12651267 backend .assert_frame_equal (
@@ -1280,7 +1282,7 @@ def test_persist_expression_contextmanager(backend, alltypes):
12801282)
12811283def test_persist_expression_contextmanager_ref_count (backend , con , alltypes ):
12821284 non_cached_table = alltypes .mutate (
1283- test_column = "calculation" , other_column = "big calc 2"
1285+ test_column = ibis . literal ( "calculation" ) , other_column = ibis . literal ( "big calc 2" )
12841286 )
12851287 op = non_cached_table .op ()
12861288 with non_cached_table .cache () as cached_table :
@@ -1304,7 +1306,7 @@ def test_persist_expression_contextmanager_ref_count(backend, con, alltypes):
13041306@mark .notimpl (["exasol" ], reason = "Exasol does not support temporary tables" )
13051307def test_persist_expression_multiple_refs (backend , con , alltypes ):
13061308 non_cached_table = alltypes .mutate (
1307- test_column = "calculation" , other_column = "big calc 2"
1309+ test_column = ibis . literal ( "calculation" ) , other_column = ibis . literal ( "big calc 2" )
13081310 )
13091311 op = non_cached_table .op ()
13101312 with non_cached_table .cache () as cached_table :
@@ -1345,7 +1347,7 @@ def test_persist_expression_multiple_refs(backend, con, alltypes):
13451347)
13461348def test_persist_expression_repeated_cache (alltypes ):
13471349 non_cached_table = alltypes .mutate (
1348- test_column = "calculation" , other_column = "big calc 2"
1350+ test_column = ibis . literal ( "calculation" ) , other_column = ibis . literal ( "big calc 2" )
13491351 )
13501352 with non_cached_table .cache () as cached_table :
13511353 with cached_table .cache () as nested_cached_table :
@@ -1374,7 +1376,7 @@ def test_persist_expression_repeated_cache(alltypes):
13741376)
13751377def test_persist_expression_release (con , alltypes ):
13761378 non_cached_table = alltypes .mutate (
1377- test_column = "calculation" , other_column = "big calc 3"
1379+ test_column = ibis . literal ( "calculation" ) , other_column = ibis . literal ( "big calc 3" )
13781380 )
13791381 cached_table = non_cached_table .cache ()
13801382 cached_table .release ()
0 commit comments