Skip to content

Commit 043bef6

Browse files
committed
Added/Updated tests\bugs\gh_8087_test.py: Checked on 6.0.0.321 #1d96c10 - all OK.
1 parent dc41662 commit 043bef6

File tree

1 file changed

+38
-0
lines changed

1 file changed

+38
-0
lines changed

tests/bugs/gh_8087_test.py

Lines changed: 38 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,38 @@
1+
#coding:utf-8
2+
3+
"""
4+
ID: issue-8087
5+
ISSUE: https://github.com/FirebirdSQL/firebird/issues/8087
6+
TITLE: AV when preparing a query with IN list that contains both literals and sub-query
7+
DESCRIPTION:
8+
NOTES:
9+
[18.04.2024] pzotov
10+
Confirmed bug (AV) on 6.0.0.315
11+
Checked on 6.0.0.321 #1d96c10 - all OK.
12+
"""
13+
14+
import pytest
15+
from firebird.qa import *
16+
17+
db = db_factory()
18+
19+
test_script = """
20+
set count on;
21+
select 1
22+
from rdb$relations r
23+
where r.rdb$relation_id in (1, (select d.rdb$relation_id from rdb$database d))
24+
rows 0
25+
;
26+
"""
27+
28+
act = isql_act('db', test_script, substitutions=[('[ \t]+', ' ')])
29+
30+
expected_stdout = """
31+
Records affected: 0
32+
"""
33+
34+
@pytest.mark.version('>=6.0.0')
35+
def test_1(act: Action):
36+
act.expected_stdout = expected_stdout
37+
act.execute(combine_output = True)
38+
assert act.clean_stdout == act.clean_expected_stdout

0 commit comments

Comments
 (0)