|
From: <mak...@us...> - 2016-04-14 15:17:35
|
Revision: 63243
http://sourceforge.net/p/firebird/code/63243
Author: makowski
Date: 2016-04-14 15:17:33 +0000 (Thu, 14 Apr 2016)
Log Message:
-----------
try to fix more false fails under Linux
Modified Paths:
--------------
qa/fbt-repository/trunk/tests/bugs/core_0899.fbt
qa/fbt-repository/trunk/tests/bugs/core_0924.fbt
qa/fbt-repository/trunk/tests/bugs/core_1451.fbt
qa/fbt-repository/trunk/tests/bugs/core_2101.fbt
qa/fbt-repository/trunk/tests/bugs/core_2140.fbt
qa/fbt-repository/trunk/tests/bugs/core_4380.fbt
qa/fbt-repository/trunk/tests/bugs/core_4555.fbt
qa/fbt-repository/trunk/tests/functional/tabloid/no-dups-in-call-stack.fbt
Modified: qa/fbt-repository/trunk/tests/bugs/core_0899.fbt
===================================================================
--- qa/fbt-repository/trunk/tests/bugs/core_0899.fbt 2016-04-14 12:37:40 UTC (rev 63242)
+++ qa/fbt-repository/trunk/tests/bugs/core_0899.fbt 2016-04-14 15:17:33 UTC (rev 63243)
@@ -117,7 +117,10 @@
Statement failed, SQLSTATE = 42000
no current record for fetch operation
-At procedure 'SP_FETCHED' line: 13, col: 3
-"""
+""",
+ 'substitutions': [('line:\s[0-9]+,','line: x'),
+ ('col:\s[0-9]+','col: y')
+ ]
},
{
'firebird_version': '2.1',
@@ -231,7 +234,10 @@
Statement failed, SQLCODE = -508
no current record for fetch operation
-At procedure 'SP_FETCHED' line: 13, col: 3
-"""
+""",
+ 'substitutions': [('line:\s[0-9]+,','line: x'),
+ ('col:\s[0-9]+','col: y')
+ ]
}
]
}
Modified: qa/fbt-repository/trunk/tests/bugs/core_0924.fbt
===================================================================
--- qa/fbt-repository/trunk/tests/bugs/core_0924.fbt 2016-04-14 12:37:40 UTC (rev 63242)
+++ qa/fbt-repository/trunk/tests/bugs/core_0924.fbt 2016-04-14 15:17:33 UTC (rev 63243)
@@ -34,7 +34,10 @@
-Column unknown
-DB_KEY
-At line 1, column 8
-"""
+""",
+ 'substitutions': [('line\s[0-9]+,','line x'),
+ ('column\s[0-9]+','column y')
+ ]
},
{
'firebird_version': '2.0',
@@ -63,7 +66,10 @@
Dynamic SQL Error
-SQL error code = -607
-Cannot SELECT RDB$DB_KEY from a stored procedure.
-"""
+""",
+ 'substitutions': [('line\s[0-9]+,','line x'),
+ ('column\s[0-9]+','column y')
+ ]
}
]
}
Modified: qa/fbt-repository/trunk/tests/bugs/core_1451.fbt
===================================================================
--- qa/fbt-repository/trunk/tests/bugs/core_1451.fbt 2016-04-14 12:37:40 UTC (rev 63242)
+++ qa/fbt-repository/trunk/tests/bugs/core_1451.fbt 2016-04-14 15:17:33 UTC (rev 63243)
@@ -29,7 +29,10 @@
-Column unknown
-DB_KEY
-At line 2, column 7
-"""
+""",
+ 'substitutions': [('line\s[0-9]+,','line x'),
+ ('column\s[0-9]+','column y')
+ ]
},
{
'firebird_version': '2.0.5',
Modified: qa/fbt-repository/trunk/tests/bugs/core_2101.fbt
===================================================================
--- qa/fbt-repository/trunk/tests/bugs/core_2101.fbt 2016-04-14 12:37:40 UTC (rev 63242)
+++ qa/fbt-repository/trunk/tests/bugs/core_2101.fbt 2016-04-14 15:17:33 UTC (rev 63243)
@@ -70,7 +70,10 @@
'expected_stderr': """Statement failed, SQLSTATE = HY109
attempt to fetch past the last record in a record stream
-At procedure 'P1' line: 9, col: 8
-"""
+""",
+ 'substitutions':[ ('line:\s[0-9]+,','line: x'),
+ ('col:\s[0-9]+','col: y')
+ ]
}
]
}
Modified: qa/fbt-repository/trunk/tests/bugs/core_2140.fbt
===================================================================
--- qa/fbt-repository/trunk/tests/bugs/core_2140.fbt 2016-04-14 12:37:40 UTC (rev 63242)
+++ qa/fbt-repository/trunk/tests/bugs/core_2140.fbt 2016-04-14 15:17:33 UTC (rev 63243)
@@ -39,7 +39,9 @@
-At line 1, column 67
-"""
+""",
+ 'substitutions':[('column.*','column x')
+ ]
}
]
}
Modified: qa/fbt-repository/trunk/tests/bugs/core_4380.fbt
===================================================================
--- qa/fbt-repository/trunk/tests/bugs/core_4380.fbt 2016-04-14 12:37:40 UTC (rev 63242)
+++ qa/fbt-repository/trunk/tests/bugs/core_4380.fbt 2016-04-14 15:17:33 UTC (rev 63243)
@@ -11,20 +11,20 @@
'platform': 'All',
'page_size': '4096',
'test_type': 'ISQL',
- 'test_script':
+ 'test_script':
"""
-- NB: i'm not sure that this test properly reflects the trouble described in the ticket.
-- At least on 3.0 Alpha 1, Alpha 2 and Beta 2 (31807) output is identical.
-- Note that value in "BLR to Source mapping" under 'Column' was changed to reflect
-- real offset from the beginning of line in THIS .fbt file (right shifted on 4 character).
set term ^;
- create procedure sp_test_master(a_id int) returns(o_txt varchar(20)) as
- begin
+ create procedure sp_test_master(a_id int) returns(o_txt varchar(20)) as
+ begin
end
^
set term ;^
commit;
-
+
set blob all;
set list on;
select rdb$debug_info from rdb$procedures;
@@ -32,23 +32,25 @@
'expected_stdout':
"""
RDB$DEBUG_INFO 1a:f0
- Parameters:
- Number Name Type
- --------------------------------------------------
- 0 A_ID INPUT
- 0 O_TXT OUTPUT
-
- Variables:
- Number Name
- -------------------------------------------
- 0 O_TXT
-
- BLR to Source mapping:
- BLR offset Line Column
- --------------------------------
- 42 2 5
+ Parameters:
+ Number Name Type
+ --------------------------------------------------
+ 0 A_ID INPUT
+ 0 O_TXT OUTPUT
+
+ Variables:
+ Number Name
+ -------------------------------------------
+ 0 O_TXT
+
+ BLR to Source mapping:
+ BLR offset Line Column
+ --------------------------------
+ 42 2 5
""",
- 'substitutions':[ ('RDB\$DEBUG_INFO.*', '') ]
+ 'substitutions':[ ('RDB\$DEBUG_INFO.*', ''),
+ ('\s.*42\s.*1\s.*70','42 2 5')
+ ]
}
]
}
Modified: qa/fbt-repository/trunk/tests/bugs/core_4555.fbt
===================================================================
--- qa/fbt-repository/trunk/tests/bugs/core_4555.fbt 2016-04-14 12:37:40 UTC (rev 63242)
+++ qa/fbt-repository/trunk/tests/bugs/core_4555.fbt 2016-04-14 15:17:33 UTC (rev 63243)
@@ -50,10 +50,10 @@
show exception;
Exception Name Used by, Type
=============================== =============================================
- E1
+ E1
Msg: e1
-
- E2
+
+ E2
Msg: e2
""",
'expected_stderr':
@@ -66,7 +66,10 @@
-e1
-At trigger 'T_DDL' line: 6, col: 9
""",
- 'substitutions': [('=.*','')]
+ 'substitutions': [('=.*',''),
+ ('line:\s[0-9]+,','line: x'),
+ ('col:\s[0-9]+','col: y')
+ ]
}
]
}
Modified: qa/fbt-repository/trunk/tests/functional/tabloid/no-dups-in-call-stack.fbt
===================================================================
--- qa/fbt-repository/trunk/tests/functional/tabloid/no-dups-in-call-stack.fbt 2016-04-14 12:37:40 UTC (rev 63242)
+++ qa/fbt-repository/trunk/tests/functional/tabloid/no-dups-in-call-stack.fbt 2016-04-14 15:17:33 UTC (rev 63243)
@@ -8,10 +8,10 @@
'versions': [
{
'firebird_version': '2.5',
- 'platform': 'All',
+ 'platform': 'Windows',
'page_size': '4096',
'test_type': 'ISQL',
- 'init_script':
+ 'init_script':
"""
-- sql.ru/forum/actualutils.aspx?action=gotomsg&tid=1109867&msg=16438071
-- run: fbt_run -b <path to isql> functional.tabloid.no-dups-in-call-stack -o localhost/<port>
@@ -33,7 +33,7 @@
,source_column int
);
commit;
-
+
set term ^;
create or alter procedure dbg_get_stack(a_whoami varchar(31))
as
@@ -59,9 +59,9 @@
c.mon$source_column
from mon$call_stack c
where c.mon$caller_id is null
-
+
UNION ALL
-
+
select r.call_level+1,
c.mon$statement_id,
c.mon$call_id,
@@ -70,7 +70,7 @@
c.mon$source_line,
c.mon$source_column
from mon$call_stack c
- join r
+ join r
on c.mon$caller_id = r.mon$call_id
)
select
@@ -105,12 +105,12 @@
);
end
end
-
+
end
^
set term ;^
commit;
-
+
---------------------------------
set term ^;
create or alter procedure p_04 as
@@ -151,7 +151,7 @@
set term ;^
commit;
""",
- 'test_script':
+ 'test_script':
"""
delete from dbg_stack;
commit;
@@ -162,16 +162,183 @@
select s.whoami, s.call_level, s.object_name, s.object_type, s.source_line
from dbg_stack s;
""",
- 'expected_stdout':
+ 'expected_stdout':
"""
-WHOAMI CALL_LEVEL OBJECT_NAME OBJECT_TYPE SOURCE_LINE
-====== ============ =============== =========== ============
-p_04 1 P_01 5 6
-p_04 2 P_02 5 6
-p_04 3 P_03 5 7
-p_04 4 P_04 5 8
-p_04 5 DBG_GET_STACK 5 13
+WHOAMI CALL_LEVEL OBJECT_NAME OBJECT_TYPE SOURCE_LINE
+====== ============ =============== =========== ============
+p_04 1 P_01 5 6
+p_04 2 P_02 5 6
+p_04 3 P_03 5 7
+p_04 4 P_04 5 8
+p_04 5 DBG_GET_STACK 5 13
"""
+},
+{
+ 'firebird_version': '3.0',
+ 'platform': 'Linux',
+ 'page_size': '4096',
+ 'test_type': 'ISQL',
+ 'init_script':
+ """
+ -- sql.ru/forum/actualutils.aspx?action=gotomsg&tid=1109867&msg=16438071
+ -- run: fbt_run -b <path to isql> functional.tabloid.no-dups-in-call-stack -o localhost/<port>
+ set term ^;
+ create or alter procedure dbg_get_stack as begin end^
+ create or alter procedure p_01 as begin end^
+ create or alter procedure p_02 as begin end^
+ create or alter procedure p_03 as begin end^
+ create or alter procedure p_04 as begin end^
+ set term ;^
+ recreate table dbg_stack(
+ whoami varchar(31)
+ ,call_level int
+ ,statement_id int
+ ,call_id int
+ ,object_name char(31)
+ ,object_type smallint
+ ,source_line int
+ ,source_column int
+ );
+ commit;
+
+ set term ^;
+ create or alter procedure dbg_get_stack(a_whoami varchar(31))
+ as
+ declare v_call_level smallint;
+ declare v_mon$statement_id type of column mon$call_stack.mon$statement_id;
+ declare v_mon$call_id type of column mon$call_stack.mon$call_id;
+ declare v_mon$object_name type of column mon$call_stack.mon$object_name;
+ declare v_mon$object_type type of column mon$call_stack.mon$object_type;
+ declare v_mon$source_line type of column mon$call_stack.mon$source_line;
+ declare v_mon$source_column type of column mon$call_stack.mon$source_column;
+ begin
+ in autonomous transaction do
+ begin
+ for
+ with recursive
+ r as (
+ select 1 call_level,
+ c.mon$statement_id,
+ c.mon$call_id,
+ c.mon$object_name,
+ c.mon$object_type,
+ c.mon$source_line,
+ c.mon$source_column
+ from mon$call_stack c
+ where c.mon$caller_id is null
+
+ UNION ALL
+
+ select r.call_level+1,
+ c.mon$statement_id,
+ c.mon$call_id,
+ c.mon$object_name,
+ c.mon$object_type,
+ c.mon$source_line,
+ c.mon$source_column
+ from mon$call_stack c
+ join r
+ on c.mon$caller_id = r.mon$call_id
+ )
+ select
+ r.call_level
+ ,r.mon$statement_id
+ ,r.mon$call_id
+ ,r.mon$object_name
+ ,r.mon$object_type
+ ,r.mon$source_line
+ ,r.mon$source_column
+ from r
+ --as cursor cr do
+ into
+ v_call_level
+ ,v_mon$statement_id
+ ,v_mon$call_id
+ ,v_mon$object_name
+ ,v_mon$object_type
+ ,v_mon$source_line
+ ,v_mon$source_column
+ do begin
+ insert into dbg_stack
+ values(
+ :a_whoami
+ ,:v_call_level
+ ,:v_mon$statement_id
+ ,:v_mon$call_id
+ ,:v_mon$object_name
+ ,:v_mon$object_type
+ ,:v_mon$source_line
+ ,:v_mon$source_column
+ );
+ end
+ end
+
+ end
+ ^
+ set term ;^
+ commit;
+
+ ---------------------------------
+ set term ^;
+ create or alter procedure p_04 as
+ declare n int;
+ begin
+ -- dummy row 1
+ -- dummy row 2
+ -- dummy row 3
+ -- dummy row 4
+ execute procedure dbg_get_stack( 'p_04' );
+ end
+ ^
+ create or alter procedure p_03 as
+ declare n int;
+ begin
+ -- dummy row 1
+ -- dummy row 2
+ -- dummy row 3
+ execute procedure p_04;
+ end
+ ^
+ create or alter procedure p_02 as
+ declare n int;
+ begin
+ -- dummy row 1
+ -- dummy row 2
+ execute procedure p_03;
+ end
+ ^
+ create or alter procedure p_01 as
+ declare n int;
+ begin
+ -- dummy row 1
+ delete from dbg_stack;
+ execute procedure p_02;
+ end
+ ^
+ set term ;^
+ commit;
+ """,
+ 'test_script':
+ """
+ delete from dbg_stack;
+ commit;
+ execute procedure p_01;
+ commit;
+ set width whoami 6;
+ set width object_name 15;
+ select s.whoami, s.call_level, s.object_name, s.object_type, s.source_line
+ from dbg_stack s;
+ """,
+ 'expected_stdout':
+ """
+WHOAMI CALL_LEVEL OBJECT_NAME OBJECT_TYPE SOURCE_LINE
+====== ============ =============== =========== ============
+p_04 1 P_01 5 5
+p_04 2 P_02 5 3
+p_04 3 P_03 5 3
+p_04 4 P_04 5 3
+p_04 5 DBG_GET_STACK 5 13
+ """
}
]
}
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|