aboutsummaryrefslogtreecommitdiffstats
path: root/test/plugin_shell.mk
diff options
context:
space:
mode:
authorLoïc Hoguin <[email protected]>2018-11-26 16:57:25 +0100
committerLoïc Hoguin <[email protected]>2018-11-26 16:57:25 +0100
commitf1ff84ab745b0dfacd56be0fb41f035e764240a3 (patch)
tree0dc4f7ecc671a3bd5e0955dc08e957b3f0603bf2 /test/plugin_shell.mk
parentd66002f706481d3a37ce2e3c81d0228d524a9e2f (diff)
downloaderlang.mk-f1ff84ab745b0dfacd56be0fb41f035e764240a3.tar.gz
erlang.mk-f1ff84ab745b0dfacd56be0fb41f035e764240a3.tar.bz2
erlang.mk-f1ff84ab745b0dfacd56be0fb41f035e764240a3.zip
Use two colons for the shell target
Diffstat (limited to 'test/plugin_shell.mk')
-rw-r--r--test/plugin_shell.mk19
1 files changed, 19 insertions, 0 deletions
diff --git a/test/plugin_shell.mk b/test/plugin_shell.mk
index 9821864..5a43678 100644
--- a/test/plugin_shell.mk
+++ b/test/plugin_shell.mk
@@ -6,6 +6,25 @@ SHELL_TARGETS = $(call list_targets,shell)
shell: $(SHELL_TARGETS)
+shell-compile: build clean
+
+ $i "Bootstrap a new OTP application named $(APP)"
+ $t mkdir $(APP)/
+ $t cp ../erlang.mk $(APP)/
+ $t $(MAKE) -C $(APP) -f erlang.mk bootstrap $v
+
+ $i "Ensure our application is recompiled before the shell runs"
+ $t perl -ni.bak -e 'print;if ($$.==1) {print "shell:: app\n"}' $(APP)/Makefile
+
+ $i "Run the shell"
+ $t $(MAKE) -C $(APP) shell SHELL_OPTS="-eval 'halt()'" $v
+
+ $i "Check that all compiled files exist"
+ $t test -f $(APP)/$(APP).d
+ $t test -f $(APP)/ebin/$(APP).app
+ $t test -f $(APP)/ebin/$(APP)_app.beam
+ $t test -f $(APP)/ebin/$(APP)_sup.beam
+
shell-default: build clean
$i "Bootstrap a new OTP library named $(APP)"