Project

General

Profile

Bug #9479

Always export TMPDIR back to the test suite's shell environment

Added by anonym over 4 years ago. Updated about 4 years ago.

Status:
Resolved
Priority:
Normal
Assignee:
-
Category:
Test suite
Target version:
Start date:
05/28/2015
Due date:
% Done:

100%

Feature Branch:
test/9479-always-export-tmpdir
Type of work:
Code
Blueprint:
Starter:
Affected tool:

Description

We should do this so that the default TMPDIR (currently /tmp/TailsToaster, as set in features/config/defaults.yml) is exported back to the environment. This way TMPDIR is always synchronized internally in the test suite and in the shell environment; without this change it's synchronized like that except in the default case, when TMPDIR wasn't in the env already, and --tmpdir wasn't passed, which is confusing, and leads to subprocesses (e.g. guestfs) using /tmp as the temporary directory.

Associated revisions

Revision 37f2778a (diff)
Added by anonym over 4 years ago

Always export TMPDIR back to the test suite's shell environment.

We should do this so that the default TMPDIR (currently
/tmp/TailsToaster, as set in features/config/defaults.yml) is exported
back to the environment. This way TMPDIR is always synchronized
internally in the test suite and in the shell environment; without
this change it's synchronized like that except in the default case,
when TMPDIR wasn't in the env already, and --tmpdir wasn't passed,
which is confusing, and leads to subprocesses (e.g. guestfs) using
/tmp as the temporary directory.

Will-fix: #9479

Revision a9a744a2
Added by intrigeri about 4 years ago

Merge remote-tracking branch 'origin/test/9479-always-export-tmpdir' into stable

Fix-committed: #9479

History

#1 Updated by anonym over 4 years ago

  • Status changed from Confirmed to In Progress

#2 Updated by anonym over 4 years ago

  • Description updated (diff)
  • Feature Branch set to https://labs.riseup.net/code/issues/9479

The code from the description is now in the feature branch, so I removed it from there.

#3 Updated by anonym over 4 years ago

  • Feature Branch changed from https://labs.riseup.net/code/issues/9479 to test/9479-always-export-tmpdir

Argh, copy-paste error.

#4 Updated by anonym over 4 years ago

  • Assignee changed from anonym to kytv
  • % Done changed from 0 to 50
  • QA Check set to Ready for QA

anonym wrote:

We should do this so that the default TMPDIR (currently /tmp/TailsToaster, as set in features/config/defaults.yml) is exported back to the environment.

Clarification: if we're no using this default, then the appropriate TMPDIR is already set in the environment (that's how we got it, after all :)).

Any way, this works well for me. The most obvious change should be that if you use the default (by not doing --tmpdir) then you'll get a /tmp/TailsToaster/.guestfs* directory; without this fix, it'd be /var/tmp/.guestfs*. Tip: clear both of these before testing, then look which one is created. Also, it will only be created if guestfs is used, so run features/untrusted_partitions.feature.

Please review, kytv!

#5 Updated by kytv over 4 years ago

  • Assignee changed from kytv to intrigeri
  • % Done changed from 50 to 60

Looks good to me and testing passes.

#6 Updated by intrigeri about 4 years ago

  • Status changed from In Progress to Fix committed
  • Assignee deleted (intrigeri)
  • % Done changed from 60 to 100
  • QA Check changed from Ready for QA to Pass

Merged! (handling Redmine blah by hand because of #9611)

#8 Updated by intrigeri about 4 years ago

  • Status changed from Fix committed to Resolved

Also available in: Atom PDF