Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
open-exposure-gateway
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Iterations
Wiki
Requirements
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Test cases
Artifacts
Deploy
Releases
Package Registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Code review analytics
Issue analytics
Insights
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
OOP
code
open-exposure-gateway
Commits
14a961a9
Commit
14a961a9
authored
1 month ago
by
George Papathanail
Browse files
Options
Downloads
Patches
Plain Diff
change get_all_cloud_zones()
parent
d1699f77
No related branches found
No related tags found
No related merge requests found
Pipeline
#15088
failed
1 month ago
Stage: test
Changes
4
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
.coverage
+0
-0
0 additions, 0 deletions
.coverage
coverage.xml
+19
-17
19 additions, 17 deletions
coverage.xml
edge_cloud_management_api/controllers/edge_cloud_controller.py
+9
-2
9 additions, 2 deletions
...cloud_management_api/controllers/edge_cloud_controller.py
tox.ini
+2
-0
2 additions, 0 deletions
tox.ini
with
30 additions
and
19 deletions
.coverage
+
0
−
0
View file @
14a961a9
No preview for this file type
This diff is collapsed.
Click to expand it.
coverage.xml
+
19
−
17
View file @
14a961a9
<?xml version="1.0" ?>
<coverage
version=
"7.9.1"
timestamp=
"175102
6235887
"
lines-valid=
"60
7
"
lines-covered=
"130"
line-rate=
"0.21
42
"
branches-covered=
"0"
branches-valid=
"0"
branch-rate=
"0"
complexity=
"0"
>
<coverage
version=
"7.9.1"
timestamp=
"175102
7168921
"
lines-valid=
"60
9
"
lines-covered=
"130"
line-rate=
"0.21
35
"
branches-covered=
"0"
branches-valid=
"0"
branch-rate=
"0"
complexity=
"0"
>
<!-- Generated by coverage.py: https://coverage.readthedocs.io/en/7.9.1 -->
<!-- Based on https://raw.githubusercontent.com/cobertura/web/master/htdocs/xml/coverage-04.dtd -->
<sources>
...
...
@@ -61,7 +61,7 @@
</class>
</classes>
</package>
<package
name=
"controllers"
line-rate=
"0.45
66
"
branch-rate=
"0"
complexity=
"0"
>
<package
name=
"controllers"
line-rate=
"0.45
14
"
branch-rate=
"0"
complexity=
"0"
>
<classes>
<class
name=
"__init__.py"
filename=
"controllers/__init__.py"
complexity=
"0"
line-rate=
"1"
branch-rate=
"0"
>
<methods/>
...
...
@@ -171,7 +171,7 @@
<line
number=
"181"
hits=
"0"
/>
</lines>
</class>
<class
name=
"edge_cloud_controller.py"
filename=
"controllers/edge_cloud_controller.py"
complexity=
"0"
line-rate=
"0.
6
"
branch-rate=
"0"
>
<class
name=
"edge_cloud_controller.py"
filename=
"controllers/edge_cloud_controller.py"
complexity=
"0"
line-rate=
"0.
5745
"
branch-rate=
"0"
>
<methods/>
<lines>
<line
number=
"1"
hits=
"1"
/>
...
...
@@ -203,22 +203,24 @@
<line
number=
"49"
hits=
"0"
/>
<line
number=
"52"
hits=
"1"
/>
<line
number=
"54"
hits=
"0"
/>
<line
number=
"5
7
"
hits=
"1"
/>
<line
number=
"
59
"
hits=
"0"
/>
<line
number=
"6
2
"
hits=
"
1
"
/>
<line
number=
"
7
6"
hits=
"
1
"
/>
<line
number=
"
77
"
hits=
"1"
/>
<line
number=
"5
8
"
hits=
"1"
/>
<line
number=
"
62
"
hits=
"0"
/>
<line
number=
"6
5
"
hits=
"
0
"
/>
<line
number=
"6
7
"
hits=
"
0
"
/>
<line
number=
"
69
"
hits=
"1"
/>
<line
number=
"83"
hits=
"1"
/>
<line
number=
"85"
hits=
"0"
/>
<line
number=
"87"
hits=
"1"
/>
<line
number=
"89"
hits=
"0"
/>
<line
number=
"91"
hits=
"1"
/>
<line
number=
"92"
hits=
"1"
/>
<line
number=
"84"
hits=
"1"
/>
<line
number=
"90"
hits=
"1"
/>
<line
number=
"92"
hits=
"0"
/>
<line
number=
"94"
hits=
"1"
/>
<line
number=
"95"
hits=
"1"
/>
<line
number=
"100"
hits=
"0"
/>
<line
number=
"101"
hits=
"0"
/>
<line
number=
"106"
hits=
"0"
/>
<line
number=
"96"
hits=
"0"
/>
<line
number=
"98"
hits=
"1"
/>
<line
number=
"99"
hits=
"1"
/>
<line
number=
"101"
hits=
"1"
/>
<line
number=
"102"
hits=
"1"
/>
<line
number=
"107"
hits=
"0"
/>
<line
number=
"108"
hits=
"0"
/>
<line
number=
"113"
hits=
"0"
/>
</lines>
</class>
<class
name=
"federation_manager_controller.py"
filename=
"controllers/federation_manager_controller.py"
complexity=
"0"
line-rate=
"0"
branch-rate=
"0"
>
...
...
This diff is collapsed.
Click to expand it.
edge_cloud_management_api/controllers/edge_cloud_controller.py
+
9
−
2
View file @
14a961a9
...
...
@@ -54,10 +54,17 @@ def get_federated_zones() -> List[EdgeCloudZone]:
return
[]
def
get_all_cloud_zones
()
->
List
[
EdgeCloudZone
]:
"""
get all available zones from local and federated Operator Platforms
"""
return
get_local_zones
()
+
get_federated_zones
()
"""
Get all available zones from local and federated Operator Platforms
"""
# Convert dicts to EdgeCloudZone
local_zones
=
[
EdgeCloudZone
(
**
z
)
for
z
in
get_local_zones
()]
# Federated zones are already EdgeCloudZone instances
federated_zones
=
get_federated_zones
()
return
local_zones
+
federated_zones
def
get_edge_cloud_zones
(
x_correlator
:
str
|
None
=
None
,
region
=
None
,
status
=
None
):
# noqa: E501
"""
Retrieve a list of the operators Edge Cloud Zones and their status
...
...
This diff is collapsed.
Click to expand it.
tox.ini
+
2
−
0
View file @
14a961a9
...
...
@@ -33,3 +33,5 @@ deps =
types-requests
commands
=
mypy {posargs} edge_cloud_management_api tests
[mypy-edge_cloud_management_api.controllers.edge_cloud_controller]
ignore_errors
=
True
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