Skip to content

Commit

Permalink
bots: Stop including bots in $PATH during tests
Browse files Browse the repository at this point in the history
We don't want our tests to rely on this, but call scripts from
`BOTS_DIR` explicitly. This will avoid traps for external Cockpit
projects, like the one fixed in commit 127211b.

Closes #10125
  • Loading branch information
martinpitt committed Sep 21, 2018
1 parent f4cd7aa commit bc07816
Showing 1 changed file with 1 addition and 4 deletions.
5 changes: 1 addition & 4 deletions bots/tests-invoke
Original file line number Diff line number Diff line change
Expand Up @@ -346,9 +346,6 @@ class PullTask(object):
ret = "Unknown context"


env = os.environ.copy()
env["PATH"] = "{0}:{1}:{2}".format(env.get("PATH", "/bin:/sbin"), BOTS, test)

# Prepare the image to run
if not ret and prefix != "cockpit":
ret = self.prepare(prefix, value, image, opts.verbose)
Expand All @@ -361,7 +358,7 @@ class PullTask(object):
if not ret:
if opts.verbose:
cmd.append("--verbose")
ret = subprocess.call(cmd, env=env)
ret = subprocess.call(cmd)

# All done
if self.sink:
Expand Down

0 comments on commit bc07816

Please sign in to comment.