[4.1] fadfbf7 Use os.path.join().

Lasse Karstensen lkarsten at varnish-software.com
Thu Mar 3 16:53:21 CET 2016


commit fadfbf7515e37a9cb25ab359b754fea2c5a85307
Author: Lasse Karstensen <lkarsten at varnish-software.com>
Date:   Thu Feb 11 12:56:33 2016 +0100

    Use os.path.join().

diff --git a/lib/libvcc/vmodtool.py b/lib/libvcc/vmodtool.py
index 07ff129..024d78a 100755
--- a/lib/libvcc/vmodtool.py
+++ b/lib/libvcc/vmodtool.py
@@ -42,7 +42,7 @@ import optparse
 import unittest
 import random
 from os import unlink
-from os.path import dirname, realpath, exists
+from os.path import dirname, exists, join, realpath
 from pprint import pprint, pformat
 
 ctypes = {
@@ -842,10 +842,10 @@ class SimpleTestCase(unittest.TestCase):
 		from glob import glob
 		tmpfile = mktemp()
 		bdir = dirname(realpath(__file__))
-		for inputfile in glob(bdir + "/../libvmod_*/vmod.vcc"):
-			runmain(inputfile, outputname=tmpfile)
-			for suffix in [".c", ".h"]:
-				unlink(tmpfile + suffix)
+		for inputfile in glob(join(bdir, "../libvmod_*/vmod.vcc")):
+			runmain(inputfile, outputprefix=tmpfile)
+			unlink(tmpfile + ".c")
+			unlink(tmpfile + ".h")
 
 
 #######################################################################



More information about the varnish-commit mailing list