setupaptarchive
-aptget install --print-uris -y cdebconf-newt-terminal cdebconf-gtk-terminal 2>&1 | sed 's#file:///tmp/tmp.[^/]\+#file:///tmp#g' > filename.log
+aptget install --print-uris -y cdebconf-newt-terminal cdebconf-gtk-terminal 2>&1 | sed "s#file://${TMPWORKINGDIRECTORY}#file:///tmp#g" > filename.log
testfileequal filename.log "Reading package lists...
Building dependency tree...
-The following extra packages will be installed:
+The following additional packages will be installed:
cdebconf-gtk-udeb cdebconf-newt-udeb cdebconf-udeb libc6-udeb
libglib2.0-udeb libgtk2.0-0-udeb libvte9-udeb
The following NEW packages will be installed: