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
7
Merge Requests
7
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Jobs
Commits
Open sidebar
Jérome Perrin
erp5
Commits
5cd935be
Commit
5cd935be
authored
Aug 14, 2023
by
Emmy Vouriot
Committed by
Jérome Perrin
May 16, 2024
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
remove encode in py3
parent
e4d33b82
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
3 deletions
+3
-3
bt5/erp5_api_style/TestTemplateItem/portal_components/test.erp5.testJioApiStyle.py
...mplateItem/portal_components/test.erp5.testJioApiStyle.py
+3
-3
No files found.
bt5/erp5_api_style/TestTemplateItem/portal_components/test.erp5.testJioApiStyle.py
View file @
5cd935be
...
@@ -604,7 +604,7 @@ return json.dumps({
...
@@ -604,7 +604,7 @@ return json.dumps({
raise
ValueError
(
"Unexcpected Answer %s"
%
response
)
raise
ValueError
(
"Unexcpected Answer %s"
%
response
)
self
.
assertEqual
(
self
.
portal
.
REQUEST
.
RESPONSE
.
getStatus
(),
201
)
self
.
assertEqual
(
self
.
portal
.
REQUEST
.
RESPONSE
.
getStatus
(),
201
)
self
.
portal
.
REQUEST
.
RESPONSE
.
setStatus
(
200
)
self
.
portal
.
REQUEST
.
RESPONSE
.
setStatus
(
200
)
person
=
self
.
portal
.
restrictedTraverse
(
response
[
'id'
].
encode
())
person
=
self
.
portal
.
restrictedTraverse
(
response
[
'id'
].
encode
()
if
six
.
PY2
else
response
[
"id"
]
)
self
.
assertEqual
(
person
.
getTitle
(),
self
.
id_template
)
self
.
assertEqual
(
person
.
getTitle
(),
self
.
id_template
)
def
createUpdateScriptjIOWebSectionCreateOrganisationFromJSON
(
self
):
def
createUpdateScriptjIOWebSectionCreateOrganisationFromJSON
(
self
):
...
@@ -651,7 +651,7 @@ return json.dumps({
...
@@ -651,7 +651,7 @@ return json.dumps({
raise
ValueError
(
"Unexcpected Answer %s"
%
response
)
raise
ValueError
(
"Unexcpected Answer %s"
%
response
)
self
.
assertEqual
(
self
.
portal
.
REQUEST
.
RESPONSE
.
getStatus
(),
201
)
self
.
assertEqual
(
self
.
portal
.
REQUEST
.
RESPONSE
.
getStatus
(),
201
)
self
.
portal
.
REQUEST
.
RESPONSE
.
setStatus
(
200
)
self
.
portal
.
REQUEST
.
RESPONSE
.
setStatus
(
200
)
organisation
=
self
.
portal
.
restrictedTraverse
(
response
[
'id'
].
encode
())
organisation
=
self
.
portal
.
restrictedTraverse
(
response
[
'id'
].
encode
()
if
six
.
PY2
else
response
[
"id"
]
)
self
.
assertEqual
(
organisation
.
getTitle
(),
self
.
id_template
)
self
.
assertEqual
(
organisation
.
getTitle
(),
self
.
id_template
)
# Check Second action
# Check Second action
response
=
json
.
loads
(
self
.
postToApi
(
response
=
json
.
loads
(
self
.
postToApi
(
...
@@ -664,7 +664,7 @@ return json.dumps({
...
@@ -664,7 +664,7 @@ return json.dumps({
raise
ValueError
(
"Unexcpected Answer %s"
%
response
)
raise
ValueError
(
"Unexcpected Answer %s"
%
response
)
self
.
assertEqual
(
self
.
portal
.
REQUEST
.
RESPONSE
.
getStatus
(),
201
)
self
.
assertEqual
(
self
.
portal
.
REQUEST
.
RESPONSE
.
getStatus
(),
201
)
self
.
portal
.
REQUEST
.
RESPONSE
.
setStatus
(
200
)
self
.
portal
.
REQUEST
.
RESPONSE
.
setStatus
(
200
)
person
=
self
.
portal
.
restrictedTraverse
(
response
[
'id'
].
encode
())
person
=
self
.
portal
.
restrictedTraverse
(
response
[
'id'
].
encode
()
if
six
.
PY2
else
response
[
"id"
]
)
self
.
assertEqual
(
person
.
getTitle
(),
self
.
id_template
)
self
.
assertEqual
(
person
.
getTitle
(),
self
.
id_template
)
def
test_action_post_no_action_matches
(
self
):
def
test_action_post_no_action_matches
(
self
):
...
...
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