Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[6.15.z] fixing make-docs issue with some update in code #1395

Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions airgun/entities/subscription.py
Original file line number Diff line number Diff line change
Expand Up @@ -48,9 +48,9 @@ def _wait_for_process_to_finish(
@property
def has_manifest(self):
"""Is there manifest present in current organization?
:return: boolean value indicating whether manifest is present
May be None if user can't verify reliably if manifest is
uploaded or not due to missing permissions

:return: boolean value indicating whether manifest is present May be None if user can't verify
reliably if manifest is uploaded or not due to missing permissions
"""
try:
view = self.navigate_to(self, 'Manage Manifest')
Expand Down
15 changes: 3 additions & 12 deletions airgun/helpers/base.py
Original file line number Diff line number Diff line change
@@ -1,22 +1,15 @@
from typing import TYPE_CHECKING

if TYPE_CHECKING:
pass


class BaseEntityHelper:
def __init__(self, entity):
# type: (BaseEntity) -> None
self._entity = entity

@property
def entity(self):
"""Returns the entity associated with this helper."""
return self._entity

def read_filled_view(
self, navigation_name, navigation_kwargs=None, values=None, read_widget_names=None
):
# type: (str, Dict, Dict[str, Any], List[str]) -> Dict[str, Any]
"""Navigate to a form using 'navigation_name' and with parameters from 'navigation_kwargs',
fill the form with values and then read values for widgets from 'read_widget_names' list if
supplied otherwise read all widgets values.
Expand All @@ -32,10 +25,8 @@ def read_filled_view(
)

"""
if navigation_kwargs is None:
navigation_kwargs = {}
if values is None:
values = {}
navigation_kwargs = navigation_kwargs or {}
values = values or {}
view = self.entity.navigate_to(self.entity, name=navigation_name, **navigation_kwargs)
view.fill(values)
return view.read(widget_names=read_widget_names)
5 changes: 3 additions & 2 deletions airgun/widgets.py
Original file line number Diff line number Diff line change
Expand Up @@ -2546,8 +2546,9 @@ class AuthSourceAggregateCard(AggregateStatusCard):

@property
def count(self):
"""Count of sources
:return int: None if no count element is found, otherwise count of sources in the card
"""Count of sources.

:return int or None: None if no count element is found, otherwise count of sources in the card.
"""
try:
return int(self.browser.text(self.browser.element(self.COUNT)))
Expand Down