From d35c04d602c9e005c125d2371ecdc5a2d0e60d33 Mon Sep 17 00:00:00 2001 From: tdruez Date: Mon, 7 Jun 2021 18:51:36 +0200 Subject: [PATCH] Fix unit test for Python 3.6/3.7 compatibility #185 Signed-off-by: tdruez --- scanpipe/tests/test_pipes.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/scanpipe/tests/test_pipes.py b/scanpipe/tests/test_pipes.py index eb3451cd3..8682aa493 100644 --- a/scanpipe/tests/test_pipes.py +++ b/scanpipe/tests/test_pipes.py @@ -429,12 +429,12 @@ def noop(*args, **kwargs): with mock.patch("scanpipe.pipes.scancode.SCANCODEIO_PROCESSES", -1): scancode._scan_and_save(project1, scan_func, noop) - with_threading = scan_func.call_args.args[-1] + with_threading = scan_func.call_args[0][-1] self.assertFalse(with_threading) with mock.patch("scanpipe.pipes.scancode.SCANCODEIO_PROCESSES", 0): scancode._scan_and_save(project1, scan_func, noop) - with_threading = scan_func.call_args.args[-1] + with_threading = scan_func.call_args[0][-1] self.assertTrue(with_threading) def test_scanpipe_pipes_scancode_virtual_codebase(self):