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
138
Merge Requests
138
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
6ee898b6
Commit
6ee898b6
authored
Feb 07, 2023
by
Julien Muchembled
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
erp5_web_shadir: update tests
See commit
c45c2295
("erp5_web_shadir: more useful checks").
parent
49dd1c9b
Pipeline
#26465
failed with stage
in 0 seconds
Changes
2
Pipelines
1
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
5 additions
and
4 deletions
+5
-4
bt5/erp5_web_shadir/TestTemplateItem/portal_components/test.erp5.ShaDirMixin.py
...stTemplateItem/portal_components/test.erp5.ShaDirMixin.py
+3
-3
bt5/erp5_web_shadir/TestTemplateItem/portal_components/test.erp5.testShaDir.py
...estTemplateItem/portal_components/test.erp5.testShaDir.py
+2
-1
No files found.
bt5/erp5_web_shadir/TestTemplateItem/portal_components/test.erp5.ShaDirMixin.py
View file @
6ee898b6
...
@@ -27,11 +27,11 @@
...
@@ -27,11 +27,11 @@
#
#
##############################################################################
##############################################################################
import
base64
import
hashlib
import
hashlib
import
json
import
json
import
platform
import
platform
import
random
import
random
from
base64
import
b64encode
from
DateTime
import
DateTime
from
DateTime
import
DateTime
...
@@ -65,14 +65,14 @@ class ShaDirMixin(object):
...
@@ -65,14 +65,14 @@ class ShaDirMixin(object):
'expiration_date'
:
str
(
self
.
expiration_date
),
'expiration_date'
:
str
(
self
.
expiration_date
),
'distribution'
:
self
.
distribution
,
'distribution'
:
self
.
distribution
,
'architecture'
:
self
.
architecture
}),
'architecture'
:
self
.
architecture
}),
"User SIGNATURE goes here."
]
b64encode
(
"User SIGNATURE goes here."
)
]
self
.
data
=
json
.
dumps
(
self
.
data_list
)
self
.
data
=
json
.
dumps
(
self
.
data_list
)
self
.
sha512sum
=
hashlib
.
sha512
(
self
.
data
).
hexdigest
()
self
.
sha512sum
=
hashlib
.
sha512
(
self
.
data
).
hexdigest
()
self
.
header_dict
=
{
self
.
header_dict
=
{
'Content-Type'
:
'application/json'
,
'Content-Type'
:
'application/json'
,
'Authorization'
:
'Basic
%s'
%
(
base64
.
encodestring
(
'ERP5TypeTestCase:'
).
strip
())
'Authorization'
:
'Basic
'
+
b64encode
(
'ERP5TypeTestCase:'
),
}
}
module
=
self
.
portal
.
web_site_module
module
=
self
.
portal
.
web_site_module
...
...
bt5/erp5_web_shadir/TestTemplateItem/portal_components/test.erp5.testShaDir.py
View file @
6ee898b6
...
@@ -32,6 +32,7 @@ import httplib
...
@@ -32,6 +32,7 @@ import httplib
import
urlparse
import
urlparse
import
json
import
json
import
random
import
random
from
base64
import
b64encode
from
unittest
import
expectedFailure
from
unittest
import
expectedFailure
from
Products.ERP5Type.tests.ERP5TypeTestCase
import
ERP5TypeTestCase
from
Products.ERP5Type.tests.ERP5TypeTestCase
import
ERP5TypeTestCase
from
erp5.component.test.ShaDirMixin
import
ShaDirMixin
from
erp5.component.test.ShaDirMixin
import
ShaDirMixin
...
@@ -224,7 +225,7 @@ class TestShaDir(ShaDirMixin, ERP5TypeTestCase):
...
@@ -224,7 +225,7 @@ class TestShaDir(ShaDirMixin, ERP5TypeTestCase):
'expiration_date'
:
str
(
self
.
expiration_date
),
'expiration_date'
:
str
(
self
.
expiration_date
),
'distribution'
:
self
.
distribution
,
'distribution'
:
self
.
distribution
,
'architecture'
:
self
.
architecture
}),
'architecture'
:
self
.
architecture
}),
"User SIGNATURE goes here."
]
b64encode
(
"User SIGNATURE goes here."
)
]
data_2
=
json
.
dumps
(
data_list_2
)
data_2
=
json
.
dumps
(
data_list_2
)
self
.
postInformation
(
key_2
,
data_2
)
self
.
postInformation
(
key_2
,
data_2
)
self
.
tic
()
self
.
tic
()
...
...
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