Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
C
CaosDB Python Integration Tests
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Iterations
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container Registry
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Code review analytics
Issue analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
caosdb
Software
CaosDB Python Integration Tests
Commits
48218a71
Commit
48218a71
authored
9 months ago
by
Florian Spreckelsen
Browse files
Options
Downloads
Patches
Plain Diff
TST: Add test for
https://gitlab.com/linkahead/linkahead-server/-/issues/264
parent
7b5662ab
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Pipeline
#52178
failed
9 months ago
Stage: info
Stage: setup
Stage: cert
Stage: style
Stage: test
Stage: deploy
Changes
1
Pipelines
29
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
tests/test_issues_server.py
+21
-1
21 additions, 1 deletion
tests/test_issues_server.py
with
21 additions
and
1 deletion
tests/test_issues_server.py
+
21
−
1
View file @
48218a71
...
...
@@ -1291,7 +1291,8 @@ def test_143_white_space(num):
]:
with
pytest
.
raises
(
TransactionError
)
as
cm
:
db
.
execute_query
(
query
)
assert
cm
.
value
.
msg
==
f
'
You typed
"
{
num
}
"
. Empty spaces are not allowed in numbers. Did you mean
"
{
num
.
replace
(
"
"
,
""
)
}
"
?
'
assert
cm
.
value
.
msg
==
(
f
'
You typed
"
{
num
}
"
. Empty spaces are not allowed
'
+
f
'
in numbers. Did you mean
"
{
num
.
replace
(
"
"
,
""
)
}
"
?
'
)
def
test_144
():
...
...
@@ -1529,3 +1530,22 @@ def test_263():
db
.
Record
(
name
=
"
1
"
).
retrieve
()
assert
len
(
exc
.
errors
)
==
1
assert
exc
.
errors
[
0
].
msg
==
"
Entity does not exist.
"
# TODO Or whatever the message shall be.
@pytest.mark.xfail
(
reason
=
"
https://gitlab.com/linkahead/linkahead-server/-/issues/264
"
)
def
test_264_accents_and_umlauts
():
"""
Test whether queries respect accents and
umlauts. https://gitlab.com/linkahead/linkahead-server/-/issues/264.
"""
# Insertes have to be possible with unique=True since the name differ in
# accents and umlauts.
rt_e
=
db
.
RecordType
(
name
=
"
Test
"
).
insert
()
rt_ë
=
db
.
RecordType
(
name
=
"
Tëst
"
).
insert
()
rt_è
=
db
.
RecordType
(
name
=
"
Tést
"
).
insert
()
# Retrieves should be unique here, too.
for
rt
in
[
rt_e
,
rt_ë
,
rt_è
]:
retrieved
=
db
.
get_entity_by_name
(
rt
.
name
)
assert
retrieved
.
id
==
rt
.
id
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment