FazBrowse GitHub Viewer
|
Trending
|
URL:
|
Home
Tools:
[Download Repo ZIP]
[View Raw Code]
[Original HTTPS Page]
python-gitlab/tests/unit/base/test_rest_manager.py at v7.1.0 · python-gitlab/python-gitlab · GitHub
python-gitlab
python-gitlab
Repository navigation
Code
Issues
16
(16)
Pull requests
15
(15)
Discussions
Actions
Projects
Security and quality
Insights
Expand file tree
Breadcrumbs
python-gitlab
/
tests
/
unit
/
base
/
test_rest_manager.py
Copy path
More file actions
More file actions
Latest commit
History
History
History
30 lines (21 loc) · 734 Bytes
Breadcrumbs
python-gitlab
/
tests
/
unit
/
base
/
test_rest_manager.py
Copy path
File metadata and controls
30 lines (21 loc) · 734 Bytes
Raw
Copy raw file
Download raw file
Open symbols panel
Edit and raw actions
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
from
gitlab
import
base
from
tests
.
unit
import
helpers
def
test_computed_path_simple
(
gl
):
class
MGR
(
base
.
RESTManager
):
_path
=
"/tests"
_obj_cls
=
object
mgr
=
MGR
(
gl
)
assert
mgr
.
_computed_path
==
"/tests"
def
test_computed_path_with_parent
(
gl
,
fake_manager
):
class
MGR
(
base
.
RESTManager
):
_path
=
"/tests/{test_id}/cases"
_obj_cls
=
object
_from_parent_attrs
=
{
"test_id"
:
"id"
}
mgr
=
MGR
(
gl
,
parent
=
helpers
.
FakeParent
(
manager
=
fake_manager
,
attrs
=
{}))
assert
mgr
.
_computed_path
==
"/tests/42/cases"
def
test_path_property
(
gl
):
class
MGR
(
base
.
RESTManager
):
_path
=
"/tests"
_obj_cls
=
object
mgr
=
MGR
(
gl
)
assert
mgr
.
path
==
"/tests"
Back
|
FazBrowse Home
|
New Git URL