Skip to content

fix lint issues #29

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

Merged
merged 5 commits into from
Mar 8, 2023
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 .github/workflows/ansible-test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ jobs:
steps:

- name: Check out code
uses: actions/checkout@v2
uses: actions/checkout@v3

- name: Perform sanity testing with ansible-test
uses: ansible-community/ansible-test-gh-action@release/v1
Expand Down Expand Up @@ -70,7 +70,7 @@ jobs:

steps:
- name: Check out code
uses: actions/checkout@v2
uses: actions/checkout@v3

- name: Perform unit testing with ansible-test
uses: ansible-community/ansible-test-gh-action@release/v1
Expand Down Expand Up @@ -115,7 +115,7 @@ jobs:

# steps:
# - name: Check out code
# uses: actions/checkout@v2
# uses: actions/checkout@v3

# - name: Perform integration testing with ansible-test
# uses: ansible-community/ansible-test-gh-action@release/v1
Expand Down
6 changes: 6 additions & 0 deletions changelogs/fragments/29-fix-lint-issues.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
bugfixes:
- fixes failures in sanity test for plugins/modules/sap_pyrfc.py
- fixes failures in sanity test for tests/unit/compat/builtins.py
- fixes failures in sanity test for tests/unit/plugins/modules/test_sap_system_facts.py
- fixes failures in sanity test for tests/unit/plugins/modules/test_sap_system_facts.py
- fixes pipeline warnings
2 changes: 1 addition & 1 deletion plugins/modules/sap_pyrfc.py
Original file line number Diff line number Diff line change
Expand Up @@ -113,7 +113,7 @@
from ..module_utils.pyrfc_handler import get_connection

try:
from pyrfc import ABAPApplicationError, ABAPRuntimeError, CommunicationError, Connection, LogonError
from pyrfc import ABAPApplicationError, ABAPRuntimeError, CommunicationError, LogonError
except ImportError:
HAS_PYRFC_LIBRARY = False
PYRFC_LIBRARY_IMPORT_ERROR = traceback.format_exc()
Expand Down
9 changes: 0 additions & 9 deletions tests/unit/compat/builtins.py
Original file line number Diff line number Diff line change
Expand Up @@ -22,12 +22,3 @@
#
# Compat for python2.7
#

# One unittest needs to import builtins via __import__() so we need to have
# the string that represents it
try:
import __builtin__
except ImportError:
BUILTINS = 'builtins'
else:
BUILTINS = '__builtin__'
3 changes: 1 addition & 2 deletions tests/unit/plugins/modules/test_sap_system_facts.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,12 +5,11 @@

from __future__ import absolute_import, division, print_function

import mock
__metaclass__ = type

from ansible_collections.community.sap_libs.plugins.modules import sap_system_facts
from ansible_collections.community.sap_libs.tests.unit.plugins.modules.utils import AnsibleExitJson, ModuleTestCase
from ansible_collections.community.sap_libs.tests.unit.compat.mock import patch, MagicMock
from ansible_collections.community.sap_libs.tests.unit.compat.mock import patch
from ansible.module_utils import basic


Expand Down