mirror of
https://github.com/FirebirdSQL/firebird-qa.git
synced 2025-02-02 02:40:42 +01:00
Added/Updated tests\bugs\core_5220_test.py: Writing code requires more care since 6.0.0.150: ISQL does not allow specifying duplicate delimiters without any statements between them (two semicolon, two carets etc).
This commit is contained in:
parent
1804767499
commit
effc0ac87b
@ -14,6 +14,9 @@ DESCRIPTION:
|
||||
These files should be equal, i.e. difference should be empty.
|
||||
JIRA: CORE-5220
|
||||
FBTEST: bugs.core_5220
|
||||
NOTES:
|
||||
[25.11.2023] pzotov
|
||||
Writing code requires more care since 6.0.0.150: ISQL does not allow specifying duplicate delimiters without any statements between them (two semicolon, two carets etc).
|
||||
"""
|
||||
|
||||
import pytest
|
||||
@ -22,7 +25,7 @@ from firebird.qa import *
|
||||
|
||||
init_script = """
|
||||
create collation "Циферки" for utf8 from unicode case insensitive 'NUMERIC-SORT=1';
|
||||
create collation "Испания" for iso8859_1 from es_es_ci_ai 'SPECIALS-FIRST=1';;
|
||||
create collation "Испания" for iso8859_1 from es_es_ci_ai 'SPECIALS-FIRST=1';
|
||||
commit;
|
||||
create domain "Артикулы" varchar(12) character set utf8 collate "Циферки";
|
||||
create domain "Комрады" varchar(40) character set iso8859_1 collate "Испания";
|
||||
@ -62,19 +65,23 @@ remove_metadata = """
|
||||
@pytest.mark.version('>=3.0')
|
||||
def test_1(act: Action):
|
||||
#
|
||||
act.isql(switches=['-x'])
|
||||
act.isql(switches=['-x'], combine_output = True)
|
||||
metadata = act.stdout
|
||||
act.reset()
|
||||
|
||||
# Remove metadata
|
||||
act.reset()
|
||||
act.expected_stdout = expected_stdout
|
||||
act.isql(switches=[], input=remove_metadata)
|
||||
act.isql(switches=[], input=remove_metadata, combine_output = True)
|
||||
assert act.clean_stdout == act.clean_expected_stdout
|
||||
act.reset()
|
||||
|
||||
# Apply metadata
|
||||
act.isql(switches=[], input=metadata, combine_output = True)
|
||||
act.reset()
|
||||
act.isql(switches=[], input=metadata)
|
||||
|
||||
# Extract metadatata again
|
||||
act.reset()
|
||||
act.isql(switches=['-x'])
|
||||
act.isql(switches=['-x'], combine_output = True)
|
||||
|
||||
# Check metadata
|
||||
meta_diff = list(unified_diff(metadata.splitlines(), act.stdout.splitlines()))
|
||||
assert meta_diff == []
|
||||
|
Loading…
Reference in New Issue
Block a user