]> git.ipfire.org Git - thirdparty/samba.git/commitdiff
python:tests:samba_tool: create temporary files under $SELFTEST_TMPDIR
authorStefan Metzmacher <metze@samba.org>
Sun, 22 Nov 2020 19:14:19 +0000 (20:14 +0100)
committerStefan Metzmacher <metze@samba.org>
Tue, 13 Apr 2021 08:23:35 +0000 (08:23 +0000)
Tests should not create files in the build nor the source directory!

Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
python/samba/tests/samba_tool/computer_edit.sh
python/samba/tests/samba_tool/contact_edit.sh
python/samba/tests/samba_tool/group_edit.sh
python/samba/tests/samba_tool/user_edit.sh

index 7459c396603fb6338b735caadb4a0214c73ce36a..9830fe3f6816d726448ea76bbdb302ffb054ab2d 100755 (executable)
@@ -23,7 +23,7 @@ display_name_new="Bjoerns new laptop"
 # echo -e "test \a string" | base64
 display_name_con_b64="dGVzdCAHIHN0cmluZwo="
 
-tmpeditor=$(mktemp --suffix .sh -p $STpath/bin samba-tool-editor-XXXXXXXX)
+tmpeditor=$(mktemp --suffix .sh -p $SELFTEST_TMPDIR samba-tool-editor-XXXXXXXX)
 chmod +x $tmpeditor
 
 create_test_computer() {
index ee9c40b59cee0c05d5671ca9b02f2cff436bbba5..038fbe2b4d718b0c159d2e2a8908d85b42751ad7 100755 (executable)
@@ -23,7 +23,7 @@ display_name_new="Renamed Bjoern"
 # echo -e "test \a string" | base64
 display_name_con_b64="dGVzdCAHIHN0cmluZwo="
 
-tmpeditor=$(mktemp --suffix .sh -p $STpath/bin samba-tool-editor-XXXXXXXX)
+tmpeditor=$(mktemp --suffix .sh -p $SELFTEST_TMPDIR samba-tool-editor-XXXXXXXX)
 chmod +x $tmpeditor
 
 create_test_contact() {
index d0428af9169b6a1c3b8631218688a1275cb5f8f5..e8e4fecb2a94a1d69f20156b2849961b52062a01 100755 (executable)
@@ -23,7 +23,7 @@ display_name_new="Users in Goettingen"
 # echo -e "test \a string" | base64
 display_name_con_b64="dGVzdCAHIHN0cmluZwo="
 
-tmpeditor=$(mktemp --suffix .sh -p $STpath/bin samba-tool-editor-XXXXXXXX)
+tmpeditor=$(mktemp --suffix .sh -p $SELFTEST_TMPDIR samba-tool-editor-XXXXXXXX)
 chmod +x $tmpeditor
 
 create_test_group() {
index ae0854e89f65fb45b55898880adceba933912023..7f0140ce6dd50c402217cbfd716ca7d01189c26a 100755 (executable)
@@ -23,7 +23,7 @@ display_name_new="Renamed Bjoern"
 # echo -e "test \a string" | base64
 display_name_con_b64="dGVzdCAHIHN0cmluZwo="
 
-tmpeditor=$(mktemp --suffix .sh -p $STpath/bin samba-tool-editor-XXXXXXXX)
+tmpeditor=$(mktemp --suffix .sh -p ${SELFTEST_TMPDIR} samba-tool-editor-XXXXXXXX)
 chmod +x $tmpeditor
 
 create_test_user() {