Skip to content

Commit ba5eecf

Browse files
committed
Added/Updated tests\bugs\gh_7731_test.py: Checked on 5.0.0.1177 (intermediate snapshots).
1 parent 97999d4 commit ba5eecf

File tree

1 file changed

+39
-0
lines changed

1 file changed

+39
-0
lines changed

tests/bugs/gh_7731_test.py

Lines changed: 39 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,39 @@
1+
#coding:utf-8
2+
3+
"""
4+
ID: issue-7731
5+
ISSUE: https://github.com/FirebirdSQL/firebird/issues/7731
6+
TITLE: Display length of timestamp with timezone is wrong in dialect 1
7+
DESCRIPTION:
8+
NOTES:
9+
[30.08.2023] pzotov
10+
Confirmed problem on 5.0.0.1169
11+
Checked on 5.0.0.1177 (intermediate snapshots).
12+
"""
13+
14+
import locale
15+
16+
import pytest
17+
from firebird.qa import *
18+
19+
db = db_factory(sql_dialect = 1)
20+
21+
test_script = f"""
22+
set heading off;
23+
SET BIND OF TIMESTAMP with time zone TO varchar;
24+
select timestamp '2023-08-29 21:22:23.0123 America/Argentina/ComodRivadavia' from rdb$database;
25+
select mon$sql_dialect from mon$database;
26+
"""
27+
28+
act = isql_act('db', test_script)
29+
30+
expected_stdout = """
31+
29-AUG-2023 21:22:23.0123 America/Argentina/ComodRivadavia
32+
1
33+
"""
34+
35+
@pytest.mark.version('>=5.0')
36+
def test_1(act: Action):
37+
act.expected_stdout = expected_stdout
38+
act.execute(combine_output = True)
39+
assert act.clean_stdout == act.clean_expected_stdout

0 commit comments

Comments
 (0)