Skip to content

Commit 47e419b

Browse files
committed
fix tests
1 parent cd0f6fb commit 47e419b

File tree

1 file changed

+14
-7
lines changed

1 file changed

+14
-7
lines changed
Lines changed: 14 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,14 @@
1-
select 'dynamic' as component,
2-
sqlpage.run_sql('tests/display_text.sql', json_object('html', html)) as properties
3-
from (
4-
select 'It ' as html
5-
union all
6-
select 'works !'
7-
) as t1;
1+
select
2+
'dynamic' as component,
3+
sqlpage.run_sql (
4+
'tests/display_text.sql',
5+
CONCAT ('{"html":"', html, '"}') -- UNSAFE. Don't do that with untrusted data. We do it here because we can't use json_object (the syntax is not the same in all supported databases)
6+
) as properties
7+
from
8+
(
9+
select
10+
'It ' as html
11+
union all
12+
select
13+
'works !'
14+
) as t1;

0 commit comments

Comments
 (0)