unicorn.git  about / heads / tags
Rack HTTP server for Unix and fast clients
blob ca9d382540950404879bb92a2598701bac72036c 469 bytes (raw)
$ git show no-kgio-wip:t/t0004-working_directory_broken.sh	# shows this blob on the CLI

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
 
#!/bin/sh
. ./test-lib.sh

t_plan 3 "config.ru is missing inside alt working_directory"

t_begin "setup" && {
	unicorn_setup
	rtmpfiles unicorn_config_tmp ok
	rm -rf $t_pfx.app
	mkdir $t_pfx.app

	# the whole point of this exercise
	echo "working_directory '$t_pfx.app'" >> $unicorn_config_tmp
}

t_begin "fails to start up w/o config.ru" && {
	unicorn -c $unicorn_config_tmp || echo ok > $ok
}

t_begin "fallback code was run" && {
	test x"$(cat $ok)" = xok
}

t_done

git clone https://yhbt.net/unicorn.git