Lines Matching refs:tmpdir

149     tmpdir="${1}"
150 rm -rf "${tmpdir}"
151 mkdir -m 0700 "${tmpdir}" || abort "Failed to create a temporary folder."
152 mkdir -p "${tmpdir}/init.d/" "${tmpdir}/rc.d/init.d/"
154 mkdir "${tmpdir}/rc${i}.d/" "${tmpdir}/rc.d/rc${i}.d/"
156 mkdir -p "${tmpdir}/runlevel/default" "${tmpdir}/runlevel/boot"
157 mkdir "${tmpdir}/run"
164 tmpdir="${tmpbase}0"
165 create_simulated_init_tree "${tmpdir}"
167 test_service "${tmpdir}" "service"
169 scripts/install_service --prefix "${tmpdir}" --enable -- --command "${tmpdir}/service" --arguments "test of my\ arguments" --description "My description" ||
172 if test -x "${tmpdir}/init.d/service"; then
173 grep "Short-Description: My description" "${tmpdir}/init.d/service" >/dev/null ||
174 fail_msg "Description not set in \"${tmpdir}/init.d/service\""
176 fail_msg "\"${tmpdir}/init.d/service\" not correctly created."
178 test -x "${tmpdir}/init.d/rc.d/service" &&
179 fail_msg "\"${tmpdir}/init.d/rc.d/service\" created but shouldn't have been."
182 if "${tmpdir}/rc3.d/S20service" --prefix "${tmpdir}" --lsb-functions "" start >/dev/null 2>&1; then
183 if grep "1: test 2: of 3: my arguments" "${tmpdir}/started" >/dev/null; then
184 test -f "${tmpdir}/stopped" &&
185 fail_msg "\"${tmpdir}/rc3.d/S20service\" stopped immediately."
187 fail_msg "\"${tmpdir}/rc3.d/S20service\" did not start correctly."
190 fail_msg "could not start \"${tmpdir}/rc3.d/S20service\"."
193 "${tmpdir}/rc.d/rc5.d/S20service" --prefix "${tmpdir}" --lsb-functions "" status >/dev/null 2>&1 ||
194 fail_msg "\"${tmpdir}/rc.d/rc5.d/S20service\" reported the wrong status."
197 if "${tmpdir}/rc.d/rc6.d/K80service" --prefix "${tmpdir}" --lsb-functions "" stop >/dev/null 2>&1; then
198 test -f "${tmpdir}/stopped" ||
199 echo "\"${tmpdir}/rc.d/rc6.d/K80service\" did not stop correctly."
201 fail_msg "could not stop \"${tmpdir}/rc.d/rc6.d/K80service\"."
204 "${tmpdir}/runlevel/service" --prefix "${tmpdir}" --lsb-functions "" status >/dev/null 2>&1 &&
205 fail_msg "\"${tmpdir}/runlevel/service\" reported the wrong status."
217 tmpdir="${tmpbase}0"
218 create_simulated_init_tree "${tmpdir}"
220 test_oneshot "${tmpdir}" "command"
222 scripts/install_service --prefix "${tmpdir}" --enable -- --command "${tmpdir}/command" --arguments "start" --description "My description" --stop-command "${tmpdir}/command" --stop-arguments "stop" --one-shot ||
225 test -f "${tmpdir}/started" &&
226 fail_msg "\"${tmpdir}/started\" already exists!"
229 if "${tmpdir}/rc3.d/S20command" --prefix "${tmpdir}" --lsb-functions "" start >/dev/null 2>&1; then
230 test -f "${tmpdir}/started" ||
231 fail_msg "\"${tmpdir}/rc3.d/S20command\" did not start correctly."
233 fail_msg "could not start \"${tmpdir}/rc3.d/S20command\"."
237 if "${tmpdir}/rc.d/rc6.d/K80command" --prefix "${tmpdir}" --lsb-functions "" stop >/dev/null 2>&1; then
238 test -f "${tmpdir}/started" &&
239 echo "\"${tmpdir}/rc.d/rc6.d/K80command\" did not stop correctly."
241 fail_msg "could not stop \"${tmpdir}/rc.d/rc6.d/K80command\"."
254 tmpdir="${tmpbase}0"
255 create_simulated_init_tree "${tmpdir}"
257 test_service "${tmpdir}" "service"
259 scripts/install_service --prefix "${tmpdir}" --enable -- --command "${tmpdir}/service" --arguments "test of my\ arguments" --description "My description" ||
262 scripts/install_service --prefix "${tmpdir}" --remove -- --command "${tmpdir}/service" ||
265 rm "${tmpdir}/service"
266 test "x`find "${tmpdir}" -type f -o -type l`" = "x" ||
279 tmpdir="${tmpbase}1"
280 create_simulated_init_tree "${tmpdir}"
282 test_service "${tmpdir}" "service"
284 scripts/install_service --prefix "${tmpdir}" --enable -- --command "${tmpdir}/service" --arguments "test of my\ arguments" --description "My description" ||
287 scripts/install_service --prefix "${tmpdir}" --disable -- --command "${tmpdir}/service" --arguments "test of my\ arguments" --description "My description" ||
289 test "x`find "${tmpdir}"/rc*.d "${tmpdir}/runlevel" -type l | wc -l`" = "x15" ||
302 tmpdir="${tmpbase}2"
303 create_simulated_init_tree "${tmpdir}"
305 test_service "${tmpdir}" "service"
307 scripts/install_service --prefix "${tmpdir}" --disable -- --command "${tmpdir}/service" --arguments "test of my\ arguments" --description "My description" ||
310 scripts/install_service --prefix "${tmpdir}" --enable -- --command "${tmpdir}/service" --arguments "test of my\ arguments" --description "My description" ||
312 test "x`find "${tmpdir}"/rc*.d "${tmpdir}/runlevel" -type l`" = "x" ||
325 tmpdir="${tmpbase}3"
326 create_simulated_init_tree "${tmpdir}"
328 test_service "${tmpdir}" "service"
330 scripts/install_service --prefix "${tmpdir}" --enable -- --command "${tmpdir}/service" --arguments "test of my\ arguments" --description "My description" ||
333 scripts/install_service --prefix "${tmpdir}" --force-disable -- --command "${tmpdir}/service" --arguments "test of my\ arguments" --description "My description" ||
335 test "x`find "${tmpdir}"/rc*.d "${tmpdir}/runlevel" -type l`" = "x" ||
348 tmpdir="${tmpbase}4"
349 create_simulated_init_tree "${tmpdir}"
351 test_service "${tmpdir}" "service"
353 scripts/install_service --prefix "${tmpdir}" --disable -- --command "${tmpdir}/service" --arguments "test of my\ arguments" --description "My description" ||
356 scripts/install_service --prefix "${tmpdir}" --force-enable -- --command "${tmpdir}/service" --arguments "test of my\ arguments" --description "My description" ||
358 test "x`find "${tmpdir}"/rc*.d "${tmpdir}/runlevel" -type l | wc -l`" = "x15" ||