X-Git-Url: https://gerrit.opnfv.org/gerrit/gitweb?a=blobdiff_plain;f=yardstick%2Fbenchmark%2Fscenarios%2Fnetworking%2Fping.py;h=d2081469751c9d53e2a0883d97d4abd6b553b4cf;hb=03d764791eeb708ade47b5e2196b18ce04552dd1;hp=6e49a143702301feda04994558e969359c4d0df4;hpb=cc337e939dd07f51d9d414cc91e312ff139a8d2d;p=yardstick.git diff --git a/yardstick/benchmark/scenarios/networking/ping.py b/yardstick/benchmark/scenarios/networking/ping.py index 6e49a1437..d20814697 100644 --- a/yardstick/benchmark/scenarios/networking/ping.py +++ b/yardstick/benchmark/scenarios/networking/ping.py @@ -9,6 +9,8 @@ # ping scenario +from __future__ import print_function +from __future__ import absolute_import import pkg_resources import logging @@ -100,7 +102,7 @@ class Ping(base.Scenario): def _test(): # pragma: no cover - '''internal test function''' + """internal test function""" key_filename = pkg_resources.resource_filename("yardstick.resources", "files/yardstick_key") ctx = { @@ -122,7 +124,8 @@ def _test(): # pragma: no cover p = Ping(args, ctx) p.run(result) - print result + print(result) + if __name__ == '__main__': # pragma: no cover _test()