File tree Expand file tree Collapse file tree 1 file changed +11
-3
lines changed
Expand file tree Collapse file tree 1 file changed +11
-3
lines changed Original file line number Diff line number Diff line change @@ -198,6 +198,14 @@ clean = function()
198198 box .schema .func .drop (prop .name )
199199 end )
200200
201+ local sql_builtin_func_count = box .space ._func :pairs ():map (function (tuple )
202+ local lang = tuple [_FUNC_LANGUAGE ]
203+ if lang == ' SQL_BUILTIN' then
204+ return 1
205+ end
206+ return 0
207+ end ):sum ()
208+
201209 cleanup_cluster ()
202210
203211 local cleanup_list = function (list , allowed )
@@ -340,9 +348,9 @@ clean = function()
340348 local user_count = box .space ._user :count ()
341349 assert (user_count == 4 or user_count == 5 ,
342350 ' box.space._user:count() should be 4 (1.10) or 5 (2.0)' )
343- local func_count = box .space ._func :count ()
344- assert ( func_count == 1 or func_count == 67 ,
345- ( ' box.space._func:count() should be 1 (1.10 and >= 2.10) or 67 (>= 2.2.1, < 2.10), %d get ' ): format ( func_count ) )
351+ assert ( box .space ._func :count () == 1 + sql_builtin_func_count ,
352+ ' box.space._func:count() should be 1 (1.10 and >= 2.10) ' ..
353+ ' or 1 + count of SQL_BUILTIN functions (>= 2.2.1, < 2.10)' )
346354 assert (box .space ._cluster :count () == 1 ,
347355 ' box.space._cluster:count() should be only one' )
348356
You can’t perform that action at this time.
0 commit comments