Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
S
slapos.core
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
Léo-Paul Géneau
slapos.core
Commits
1f04923a
Commit
1f04923a
authored
Nov 09, 2022
by
Rafael Monnerat
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
slapos_erp5: Test Precache Manifest Scripts
Ensure that all files exists and are reacheable.
parent
97765a8a
Changes
6
Show whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
176 additions
and
3 deletions
+176
-3
master/bt5/slapos_erp5/TestTemplateItem/portal_components/test.erp5.testSlapOSCodingStyle.py
...Item/portal_components/test.erp5.testSlapOSCodingStyle.py
+0
-1
master/bt5/slapos_erp5/TestTemplateItem/portal_components/test.erp5.testSlapOSPrecacheManifest.py
...portal_components/test.erp5.testSlapOSPrecacheManifest.py
+61
-0
master/bt5/slapos_erp5/TestTemplateItem/portal_components/test.erp5.testSlapOSPrecacheManifest.xml
...ortal_components/test.erp5.testSlapOSPrecacheManifest.xml
+112
-0
master/bt5/slapos_erp5/bt/template_test_id_list
master/bt5/slapos_erp5/bt/template_test_id_list
+2
-1
master/bt5/slapos_jio_ui_test/PathTemplateItem/portal_tests/slapos_renderjs_runner_zuite/testSlapOSJSRenderJSRunner0ServiceWorker.xml
...runner_zuite/testSlapOSJSRenderJSRunner0ServiceWorker.xml
+1
-1
master/bt5/slapos_jio_ui_test/PathTemplateItem/portal_tests/slapos_renderjs_runner_zuite/testSlapOSJSRenderJSRunner0ServiceWorker.zpt
...runner_zuite/testSlapOSJSRenderJSRunner0ServiceWorker.zpt
+0
-0
No files found.
master/bt5/slapos_erp5/TestTemplateItem/portal_components/test.erp5.testSlapOSCodingStyle.py
View file @
1f04923a
...
...
@@ -341,7 +341,6 @@ def makeTestSlapOSCodingStyleTestCase(tested_business_template):
'slapos_base/Login_notifyPasswordExpire'
,
'slapos_base/Person_applyContractInvitation'
,
'slapos_base/ERP5Site_getAvailableOAuthLoginList'
,
'slapos_base/WebSection_getHostingJSPrecacheManifestList'
,
'slapos_erp5/CatalogTool_checkNoneCreationDateConsistency'
,
'slapos_erp5/CertificateAuthorityTool_checkCertificateAuthorityConsistency'
,
'slapos_erp5/CertificateAuthorityTool_checkSlapOSMachineNonExistenceConsistency'
,
...
...
master/bt5/slapos_erp5/TestTemplateItem/portal_components/test.erp5.testSlapOSPrecacheManifest.py
0 → 100644
View file @
1f04923a
# -*- coding: utf-8 -*-
##############################################################################
#
# Copyright (C) 2013-2019 Nexedi SA and Contributors.
#
# This program is free software: you can Use, Study, Modify and Redistribute
# it under the terms of the GNU General Public License version 3, or (at your
# option) any later version, as published by the Free Software Foundation.
#
# You can also Link and Combine this program with other software covered by
# the terms of any of the Free Software licenses or any of the Open Source
# Initiative approved licenses and Convey the resulting work. Corresponding
# source of such a combination shall include the source code for all other
# software used.
#
# This program is distributed WITHOUT ANY WARRANTY; without even the implied
# warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
#
# See COPYING file for full licensing terms.
# See https://www.nexedi.com/licensing for rationale and options.
#
##############################################################################
from
erp5.component.test.SlapOSTestCaseMixin
import
\
SlapOSTestCaseMixinWithAbort
class
TestSlapOSHostingJSPrecacheManifestList
(
SlapOSTestCaseMixinWithAbort
):
manifest_script_id
=
'WebSection_getHostingJSPrecacheManifestList'
def
isPublishedWebPage
(
self
,
reference
):
return
self
.
web_site
.
getDocumentValue
(
reference
)
is
not
None
def
isPath
(
self
,
reference
):
return
self
.
portal
.
restrictedTraverse
(
reference
,
None
)
is
not
None
def
test
(
self
):
self
.
web_site
=
self
.
portal
.
web_site_module
.
renderjs_runner
self
.
changeSkin
(
'Hal'
)
manifest_script
=
getattr
(
self
.
web_site
,
self
.
manifest_script_id
)
failure_list
=
[]
self
.
logout
()
for
_entry
in
manifest_script
():
# Normalize url
entry
=
_entry
.
split
(
'?'
)[
0
]
if
not
(
self
.
isPublishedWebPage
(
entry
)
or
\
self
.
isPath
(
entry
)):
failure_list
.
append
(
entry
)
self
.
assertEqual
(
failure_list
,
[])
class
TestSlapOSRenderJSRunnerAccessPagePrecacheManifestList
(
TestSlapOSHostingJSPrecacheManifestList
):
manifest_script_id
=
'WebSection_getRenderJSRunnerAccessPagePrecacheManifestList'
class
TestSlapOSMonacoEditorPrecacheManifestList
(
TestSlapOSHostingJSPrecacheManifestList
):
manifest_script_id
=
'WebSection_getMonacoEditorPrecacheManifestList'
master/bt5/slapos_erp5/TestTemplateItem/portal_components/test.erp5.testSlapOSPrecacheManifest.xml
0 → 100644
View file @
1f04923a
<?xml version="1.0"?>
<ZopeData>
<record
id=
"1"
aka=
"AAAAAAAAAAE="
>
<pickle>
<global
name=
"Test Component"
module=
"erp5.portal_type"
/>
</pickle>
<pickle>
<dictionary>
<item>
<key>
<string>
default_reference
</string>
</key>
<value>
<string>
testSlapOSPrecacheManifest
</string>
</value>
</item>
<item>
<key>
<string>
default_source_reference
</string>
</key>
<value>
<none/>
</value>
</item>
<item>
<key>
<string>
description
</string>
</key>
<value>
<none/>
</value>
</item>
<item>
<key>
<string>
id
</string>
</key>
<value>
<string>
test.erp5.testSlapOSPrecacheManifest
</string>
</value>
</item>
<item>
<key>
<string>
portal_type
</string>
</key>
<value>
<string>
Test Component
</string>
</value>
</item>
<item>
<key>
<string>
sid
</string>
</key>
<value>
<none/>
</value>
</item>
<item>
<key>
<string>
text_content_error_message
</string>
</key>
<value>
<tuple/>
</value>
</item>
<item>
<key>
<string>
text_content_warning_message
</string>
</key>
<value>
<tuple/>
</value>
</item>
<item>
<key>
<string>
version
</string>
</key>
<value>
<string>
erp5
</string>
</value>
</item>
<item>
<key>
<string>
workflow_history
</string>
</key>
<value>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAAI=
</string>
</persistent>
</value>
</item>
</dictionary>
</pickle>
</record>
<record
id=
"2"
aka=
"AAAAAAAAAAI="
>
<pickle>
<global
name=
"PersistentMapping"
module=
"Persistence.mapping"
/>
</pickle>
<pickle>
<dictionary>
<item>
<key>
<string>
data
</string>
</key>
<value>
<dictionary>
<item>
<key>
<string>
component_validation_workflow
</string>
</key>
<value>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAAM=
</string>
</persistent>
</value>
</item>
</dictionary>
</value>
</item>
</dictionary>
</pickle>
</record>
<record
id=
"3"
aka=
"AAAAAAAAAAM="
>
<pickle>
<global
name=
"WorkflowHistoryList"
module=
"Products.ERP5Type.Workflow"
/>
</pickle>
<pickle>
<dictionary>
<item>
<key>
<string>
_log
</string>
</key>
<value>
<list>
<dictionary>
<item>
<key>
<string>
action
</string>
</key>
<value>
<string>
validate
</string>
</value>
</item>
<item>
<key>
<string>
validation_state
</string>
</key>
<value>
<string>
validated
</string>
</value>
</item>
</dictionary>
</list>
</value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
master/bt5/slapos_erp5/bt/template_test_id_list
View file @
1f04923a
...
...
@@ -9,3 +9,4 @@ test.erp5.testSlapOSCodingStyle
test.erp5.testSlapOSAuthenticationPolicy
test.erp5.testSlapOSERP5InteractionWorkflow
test.erp5.testSlapOSWendelinCoreTwo
test.erp5.testSlapOSPrecacheManifest
\ No newline at end of file
master/bt5/slapos_jio_ui_test/PathTemplateItem/portal_tests/slapos_renderjs_runner_zuite/testSlapOSRenderJSRunner0ServiceWorker.xml
→
master/bt5/slapos_jio_ui_test/PathTemplateItem/portal_tests/slapos_renderjs_runner_zuite/testSlapOS
JS
RenderJSRunner0ServiceWorker.xml
View file @
1f04923a
...
...
@@ -42,7 +42,7 @@
</item>
<item>
<key>
<string>
id
</string>
</key>
<value>
<string>
testSlapOSRenderJSRunner0ServiceWorker
</string>
</value>
<value>
<string>
testSlapOS
JS
RenderJSRunner0ServiceWorker
</string>
</value>
</item>
<item>
<key>
<string>
output_encoding
</string>
</key>
...
...
master/bt5/slapos_jio_ui_test/PathTemplateItem/portal_tests/slapos_renderjs_runner_zuite/testSlapOSRenderJSRunner0ServiceWorker.zpt
→
master/bt5/slapos_jio_ui_test/PathTemplateItem/portal_tests/slapos_renderjs_runner_zuite/testSlapOS
JS
RenderJSRunner0ServiceWorker.zpt
View file @
1f04923a
File moved
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