Skip to content

Commit 6d66f8f

Browse files
committedOct 5, 2020
Fix flake8 tests
1 parent 3928960 commit 6d66f8f

File tree

2 files changed

+4
-6
lines changed

2 files changed

+4
-6
lines changed
 

‎tests/servicenow_base_action_test_case.py

-1
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,6 @@
1313
# See the License for the specific language governing permissions and
1414

1515
import yaml
16-
import sys
1716

1817
from st2tests.base import BaseActionTestCase
1918

‎tests/test_upload_attachment.py

+4-5
Original file line numberDiff line numberDiff line change
@@ -13,8 +13,6 @@
1313
# See the License for the specific language governing permissions and
1414

1515
import mock
16-
import yaml
17-
import sys
1816

1917
from servicenow_base_action_test_case import ServiceNowBaseActionTestCase
2018
from upload_attachment import UploadAttachmentAction
@@ -30,8 +28,9 @@ def setUp(self):
3028
@mock.patch('pysnow.Client')
3129
def test_add_attachment(self, mock_client):
3230
action = self.get_action_instance(self.full_config)
33-
result = action.run('table1','file1','sysid1')
34-
mock_client.return_value.query.assert_called_with(table="table1", query={'sys_id': "sysid1"})
35-
mock_client.return_value.query.return_value.attach.assert_called_with('file1')
31+
result = action.run('table1', 'file1', 'sysid1')
32+
mock_client.return_value.query.assert_called_with(table="table1",
33+
query={'sys_id': "sysid1"})
34+
mock_client.return_value.query.return_value.attach.assert_called_with('file1')
3635
self.assertIsNotNone(result)
3736
self.assertTrue(result[0])

0 commit comments

Comments
 (0)