From: Kamalesh Babulal Date: Thu, 8 Aug 2024 11:05:55 +0000 (+0530) Subject: ftests/process: Fix quote warnings X-Git-Tag: v3.2.0~55 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=6012599b915a0ee9fdb4693ff0e85185e59b7ff4;p=thirdparty%2Flibcgroup.git ftests/process: Fix quote warnings Fix multiple "Q000 Double quotes found but single quotes preferred" warnings. Signed-off-by: Kamalesh Babulal Signed-off-by: Tom Hromatka --- diff --git a/tests/ftests/process.py b/tests/ftests/process.py index d03de98f..021d9f29 100644 --- a/tests/ftests/process.py +++ b/tests/ftests/process.py @@ -35,8 +35,8 @@ class Process(object): @staticmethod def __infinite_loop(config, sleep_time=1): - cmd = ["/usr/bin/perl", - "-e", + cmd = ['/usr/bin/perl', + '-e', "'while(1){{sleep({})}};'".format(sleep_time) ] @@ -53,8 +53,8 @@ class Process(object): @staticmethod def __cgexec_infinite_loop(config, controller, cgname, sleep_time=1, ignore_systemd=False, replace_idle=False): - cmd = ["/usr/bin/perl", - "-e", + cmd = ['/usr/bin/perl', + '-e', "'while(1){{sleep({})}};'".format(sleep_time) ] @@ -70,7 +70,7 @@ class Process(object): # get the PID of the newly spawned infinite loop cmd = ( "ps x | grep perl | grep 'sleep({})' | awk '{{print $1}}'" - "".format(sleep_time) + ''.format(sleep_time) ) if config.args.container: