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
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
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
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
amrani
erp5
Commits
483462da
Commit
483462da
authored
Jan 11, 2018
by
Arnaud Fontaine
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
erp5_budget: Fix errors/warnings reported by pylint.
parent
e3fdab55
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
13 additions
and
11 deletions
+13
-11
product/ERP5/tests/testBudget.py
product/ERP5/tests/testBudget.py
+13
-11
No files found.
product/ERP5/tests/testBudget.py
View file @
483462da
...
@@ -85,7 +85,7 @@ class TestBudget(ERP5TypeTestCase):
...
@@ -85,7 +85,7 @@ class TestBudget(ERP5TypeTestCase):
budget
=
self
.
portal
.
budget_module
.
newContent
(
budget
=
self
.
portal
.
budget_module
.
newContent
(
portal_type
=
'Budget'
)
portal_type
=
'Budget'
)
budget_line
=
budget
.
newContent
(
portal_type
=
'Budget Line'
)
budget_line
=
budget
.
newContent
(
portal_type
=
'Budget Line'
)
budget_
cell
=
budget_
line
.
newContent
(
portal_type
=
'Budget Cell'
)
budget_line
.
newContent
(
portal_type
=
'Budget Cell'
)
self
.
assertEqual
([],
budget
.
checkConsistency
())
self
.
assertEqual
([],
budget
.
checkConsistency
())
def
test_budget_cell_node_variation_with_aggregate
(
self
):
def
test_budget_cell_node_variation_with_aggregate
(
self
):
...
@@ -626,17 +626,18 @@ class TestBudget(ERP5TypeTestCase):
...
@@ -626,17 +626,18 @@ class TestBudget(ERP5TypeTestCase):
self
.
assertEqual
(
2
,
len
(
budget_line
.
contentValues
()))
self
.
assertEqual
(
2
,
len
(
budget_line
.
contentValues
()))
test_class_self
=
self
class
ReferenceQuery
:
class
ReferenceQuery
:
"""Helper class to compare queries
"""Helper class to compare queries
"""
"""
def
__eq__
(
me
,
query
):
def
__eq__
(
self
,
query
):
self
.
assertTrue
(
isinstance
(
query
,
ComplexQuery
))
test_class_
self
.
assertTrue
(
isinstance
(
query
,
ComplexQuery
))
self
.
assertEqual
(
query
.
logical_operator
,
'or'
)
test_class_
self
.
assertEqual
(
query
.
logical_operator
,
'or'
)
self
.
assertEqual
(
2
,
len
(
query
.
query_list
))
test_class_
self
.
assertEqual
(
2
,
len
(
query
.
query_list
))
self
.
assertEqual
(
query
.
query_list
[
0
].
kw
,
{
'project_uid'
:
None
})
test_class_
self
.
assertEqual
(
query
.
query_list
[
0
].
kw
,
{
'project_uid'
:
None
})
self
.
assertEqual
(
query
.
query_list
[
1
].
kw
,
test_class_
self
.
assertEqual
(
query
.
query_list
[
1
].
kw
,
{
'project_uid'
:
{
'project_uid'
:
[
self
.
portal
.
organisation_module
.
my_organisation
.
getUid
()]})
[
test_class_
self
.
portal
.
organisation_module
.
my_organisation
.
getUid
()]})
return
True
return
True
self
.
assertEqual
(
self
.
assertEqual
(
...
@@ -730,12 +731,13 @@ class TestBudget(ERP5TypeTestCase):
...
@@ -730,12 +731,13 @@ class TestBudget(ERP5TypeTestCase):
self
.
assertEqual
(
1
,
len
(
budget_line
.
contentValues
()))
self
.
assertEqual
(
1
,
len
(
budget_line
.
contentValues
()))
test_class_self
=
self
class
ReferenceQuery
:
class
ReferenceQuery
:
"""Helper class to compare queries
"""Helper class to compare queries
"""
"""
def
__eq__
(
me
,
query
):
def
__eq__
(
self
,
query
):
self
.
assertTrue
(
isinstance
(
query
,
Query
))
test_class_
self
.
assertTrue
(
isinstance
(
query
,
Query
))
self
.
assertEqual
(
query
.
kw
,
{
'project_uid'
:
None
})
test_class_
self
.
assertEqual
(
query
.
kw
,
{
'project_uid'
:
None
})
return
True
return
True
self
.
assertEqual
(
self
.
assertEqual
(
...
...
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