Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
erp5
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Labels
Merge Requests
143
Merge Requests
143
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Jobs
Commits
Open sidebar
nexedi
erp5
Commits
0ec2df7e
Commit
0ec2df7e
authored
Feb 01, 2024
by
Jérome Perrin
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
test: expectedFailure on python3 can only be set on test method
parent
79a88d5d
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
8 additions
and
6 deletions
+8
-6
bt5/erp5_trade/TestTemplateItem/portal_components/test.erp5.testResource.py
...tTemplateItem/portal_components/test.erp5.testResource.py
+3
-1
bt5/erp5_web_shadir/TestTemplateItem/portal_components/test.erp5.testShaDir.py
...estTemplateItem/portal_components/test.erp5.testShaDir.py
+3
-1
bt5/erp5_web_ui_test/TestTemplateItem/portal_components/test.erp5.testStaticWebSiteRedirection.py
...rtal_components/test.erp5.testStaticWebSiteRedirection.py
+1
-1
product/ZSQLCatalog/tests/testSQLCatalog.py
product/ZSQLCatalog/tests/testSQLCatalog.py
+1
-3
No files found.
bt5/erp5_trade/TestTemplateItem/portal_components/test.erp5.testResource.py
View file @
0ec2df7e
...
@@ -1419,6 +1419,7 @@ class TestResource(ERP5TypeTestCase):
...
@@ -1419,6 +1419,7 @@ class TestResource(ERP5TypeTestCase):
self
.
assertEqual
(
resource
.
getInternalSupplyLineDestinationReference
(),
self
.
assertEqual
(
resource
.
getInternalSupplyLineDestinationReference
(),
'test_destination_reference_on_internal_supply_line'
)
'test_destination_reference_on_internal_supply_line'
)
@
expectedFailure
def
testQuantityUnitOnMovement
(
self
):
def
testQuantityUnitOnMovement
(
self
):
"""Make sure that changing default quantity unit on resource does not
"""Make sure that changing default quantity unit on resource does not
affect to movement.
affect to movement.
...
@@ -1471,7 +1472,8 @@ class TestResource(ERP5TypeTestCase):
...
@@ -1471,7 +1472,8 @@ class TestResource(ERP5TypeTestCase):
# Check existing movement again and make sure that quantity
# Check existing movement again and make sure that quantity
# unit is not changed.
# unit is not changed.
expectedFailure
(
self
.
assertEqual
)(
# XXX This is the expectedFailure
self
.
assertEqual
(
sale_order_line
.
getQuantityUnitValue
(),
sale_order_line
.
getQuantityUnitValue
(),
self
.
quantity_unit_gram
)
self
.
quantity_unit_gram
)
...
...
bt5/erp5_web_shadir/TestTemplateItem/portal_components/test.erp5.testShaDir.py
View file @
0ec2df7e
...
@@ -164,6 +164,7 @@ class TestShaDir(ShaDirMixin, ERP5TypeTestCase):
...
@@ -164,6 +164,7 @@ class TestShaDir(ShaDirMixin, ERP5TypeTestCase):
self
.
assertEqual
(
1
,
len
(
information_list
))
self
.
assertEqual
(
1
,
len
(
information_list
))
self
.
assertEqual
(
json
.
dumps
(
information_list
[
0
]),
self
.
data
)
self
.
assertEqual
(
json
.
dumps
(
information_list
[
0
]),
self
.
data
)
@
expectedFailure
def
test_post_information_more_than_once_no_tic
(
self
):
def
test_post_information_more_than_once_no_tic
(
self
):
"""
"""
Check if posting information is working.
Check if posting information is working.
...
@@ -174,7 +175,8 @@ class TestShaDir(ShaDirMixin, ERP5TypeTestCase):
...
@@ -174,7 +175,8 @@ class TestShaDir(ShaDirMixin, ERP5TypeTestCase):
self
.
postInformation
()
self
.
postInformation
()
self
.
tic
()
self
.
tic
()
expectedFailure
(
self
.
assertEqual
)(
1
,
# XXX this is the expected failure
self
.
assertEqual
(
1
,
self
.
portal
.
portal_catalog
.
countResults
(
reference
=
self
.
key
)[
0
][
0
])
self
.
portal
.
portal_catalog
.
countResults
(
reference
=
self
.
key
)[
0
][
0
])
data_set
=
self
.
portal
.
portal_catalog
.
getResultValue
(
data_set
=
self
.
portal
.
portal_catalog
.
getResultValue
(
reference
=
self
.
key
)
reference
=
self
.
key
)
...
...
bt5/erp5_web_ui_test/TestTemplateItem/portal_components/test.erp5.testStaticWebSiteRedirection.py
View file @
0ec2df7e
...
@@ -73,7 +73,7 @@ class TestStaticWebSiteRedirection(ERP5TypeTestCase):
...
@@ -73,7 +73,7 @@ class TestStaticWebSiteRedirection(ERP5TypeTestCase):
self
.
tic
()
self
.
tic
()
return
website
return
website
def
runTestRedirect
(
self
,
source_path
,
expected_failure
=
None
,
def
runTestRedirect
(
self
,
source_path
,
use_moved_temporarily
=
None
,
use_moved_temporarily
=
None
,
configuration_service_worker_url
=
None
,
**
kw
):
configuration_service_worker_url
=
None
,
**
kw
):
"""
"""
...
...
product/ZSQLCatalog/tests/testSQLCatalog.py
View file @
0ec2df7e
...
@@ -265,12 +265,10 @@ class TestSQLCatalog(ERP5TypeTestCase):
...
@@ -265,12 +265,10 @@ class TestSQLCatalog(ERP5TypeTestCase):
self
.
assertRaises
(
exception
,
self
.
_catalog
,
src__
=
1
,
query_table
=
'foo'
,
**
kw
)
self
.
assertRaises
(
exception
,
self
.
_catalog
,
src__
=
1
,
query_table
=
'foo'
,
**
kw
)
def
catalog
(
self
,
reference_tree
,
kw
,
check_search_text
=
True
,
def
catalog
(
self
,
reference_tree
,
kw
,
check_search_text
=
True
,
check_select_expression
=
True
,
expected_failure
=
False
):
check_select_expression
=
True
):
reference_param_dict
=
self
.
_catalog
.
buildSQLQuery
(
query_table
=
'foo'
,
**
kw
)
reference_param_dict
=
self
.
_catalog
.
buildSQLQuery
(
query_table
=
'foo'
,
**
kw
)
query
=
self
.
_catalog
.
buildEntireQuery
(
kw
).
query
query
=
self
.
_catalog
.
buildEntireQuery
(
kw
).
query
assertEqual
=
self
.
assertEqual
assertEqual
=
self
.
assertEqual
if
expected_failure
:
assertEqual
=
unittest
.
expectedFailure
(
assertEqual
)
assertEqual
(
reference_tree
,
query
)
assertEqual
(
reference_tree
,
query
)
search_text
=
query
.
asSearchTextExpression
(
self
.
_catalog
)
search_text
=
query
.
asSearchTextExpression
(
self
.
_catalog
)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment