Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
slapos
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
Xavier Thompson
slapos
Commits
d095be0c
Commit
d095be0c
authored
Apr 09, 2021
by
Łukasz Nowak
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
monitor: Expose explicitly slave issue
parent
35697982
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
47 additions
and
0 deletions
+47
-0
software/monitor/test/test.py
software/monitor/test/test.py
+47
-0
No files found.
software/monitor/test/test.py
View file @
d095be0c
...
...
@@ -31,6 +31,7 @@ import os
import
re
import
requests
import
subprocess
import
unittest
import
xml.etree.ElementTree
as
ET
from
slapos.recipe.librecipe
import
generateHashFromFiles
from
slapos.testing.testcase
import
makeModuleSetUpAndTestCaseClass
...
...
@@ -492,3 +493,49 @@ URL =
'backend'
,
{
'url'
:
'https://www.erp5.com/'
},
)
class
TestEdgeSlaveNotJson
(
EdgeSlaveMixin
,
SlapOSInstanceTestCase
):
surykatka_dict
=
{
2
:
{
'expected_ini'
:
"""[SURYKATKA]
INTERVAL = 120
TIMEOUT = 4
SQLITE = %(db_file)s
URL =
https://www.erp5.com/"""
}
}
# non-json provided in slave '_' results with damaging the cluster
# test here is to expose real problem, which has no solution for now
@
unittest
.
expectedFailure
def
test
(
self
):
EdgeSlaveMixin
.
test
()
def
assertSurykatkaPromises
(
self
):
self
.
assertPromiseContent
(
'http-query-default-promise.py'
,
"""extra_config_dict = { 'certificate-expiration-days': '15',
'failure-amount': '2',
'http-header-dict': '{}',
'ip-list': '',
'json-file': '%s',
'maximum-elapsed-time': '2',
'report': 'http_query',
'status-code': '200',
'url': 'https://www.default.org/'}"""
%
(
self
.
surykatka_dict
[
2
][
'json-file'
],))
def
requestEdgetestSlaves
(
self
):
self
.
requestEdgetestSlave
(
'default'
,
{
'url'
:
'https://www.default.org/'
},
)
software_url
=
self
.
getSoftwareURL
()
self
.
slap
.
request
(
software_release
=
software_url
,
software_type
=
'edgetest'
,
partition_reference
=
'notajson'
,
partition_parameter_kw
=
{
'_'
:
'notajson'
},
shared
=
True
)
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