Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
C
Coopdevs OCB mirror
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
External wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package registry
Container registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository 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
Coopdevs
Odoo
Coopdevs OCB mirror
Commits
2a65b815
Commit
2a65b815
authored
8 years ago
by
Christophe Simonis
Browse files
Options
Downloads
Patches
Plain Diff
[FIX] base: run defined modifiers tests
parent
863f46ec
Branches
Branches containing commit
Tags
Tags containing commit
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
openerp/addons/base/tests/test_views.py
+5
-0
5 additions, 0 deletions
openerp/addons/base/tests/test_views.py
openerp/osv/orm.py
+4
-4
4 additions, 4 deletions
openerp/osv/orm.py
with
9 additions
and
4 deletions
openerp/addons/base/tests/test_views.py
+
5
−
0
View file @
2a65b815
...
...
@@ -9,6 +9,7 @@ from lxml.builder import E
from
psycopg2
import
IntegrityError
from
openerp.osv.orm
import
modifiers_tests
from
openerp.exceptions
import
ValidationError
from
openerp.tests
import
common
import
openerp.tools
...
...
@@ -854,6 +855,10 @@ class test_views(ViewCase):
string
=
"
Replacement title
"
,
version
=
"
7.0
"
))
def
test_modifiers
(
self
):
# implemeted elsewhere...
modifiers_tests
()
class
ViewModeField
(
ViewCase
):
"""
This should probably, eventually, be folded back into other test case
...
...
This diff is collapsed.
Click to expand it.
openerp/osv/orm.py
+
4
−
4
View file @
2a65b815
...
...
@@ -118,13 +118,13 @@ def test_modifiers(what, expected):
node
=
etree
.
fromstring
(
what
)
transfer_node_to_modifiers
(
node
,
modifiers
)
simplify_modifiers
(
modifiers
)
json
=
simplejson
.
dumps
(
modifiers
)
assert
json
==
expected
,
"
%s != %s
"
%
(
json
,
expected
)
dumped
=
simplejson
.
dumps
(
modifiers
)
assert
dumped
==
expected
,
"
%s != %s
"
%
(
dumped
,
expected
)
elif
isinstance
(
what
,
dict
):
transfer_field_to_modifiers
(
what
,
modifiers
)
simplify_modifiers
(
modifiers
)
json
=
simplejson
.
dumps
(
modifiers
)
assert
json
==
expected
,
"
%s != %s
"
%
(
json
,
expected
)
dumped
=
simplejson
.
dumps
(
modifiers
)
assert
dumped
==
expected
,
"
%s != %s
"
%
(
dumped
,
expected
)
# To use this test:
...
...
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