summaryrefslogtreecommitdiff
path: root/tests/make-test-app.sh
diff options
context:
space:
mode:
authorAlexander Larsson <alexl@redhat.com>2016-02-25 14:33:59 +0100
committerAlexander Larsson <alexl@redhat.com>2016-02-25 15:14:57 +0100
commit0e595519c1999317c75aa17bb5cd10d9509f6cbe (patch)
tree7407b5541cddf0c5a0158577bebd2e2728f53af4 /tests/make-test-app.sh
parentf89e004fa3a04fc5a1d5e9613e2bb70c0eeee9fe (diff)
downloadflatpak-0e595519c1999317c75aa17bb5cd10d9509f6cbe.tar.gz
Add test scripts that create trivial a runtime and app
Diffstat (limited to 'tests/make-test-app.sh')
-rwxr-xr-xtests/make-test-app.sh19
1 files changed, 19 insertions, 0 deletions
diff --git a/tests/make-test-app.sh b/tests/make-test-app.sh
new file mode 100755
index 00000000..31a9239a
--- /dev/null
+++ b/tests/make-test-app.sh
@@ -0,0 +1,19 @@
+#!/bin/sh
+
+set -e
+
+DIR=`mktemp -d`
+
+# Init dir
+xdg-app build-init ${DIR} org.test.Hello org.test.Platform org.test.Platform
+
+mkdir -p ${DIR}/files/bin
+cat > ${DIR}/files/bin/hello.sh <<EOF
+#!/bin/sh
+echo "Hello world, from a sandbox"
+EOF
+chmod a+x ${DIR}/files/bin/hello.sh
+
+xdg-app build-finish --command=hello.sh ${DIR}
+xdg-app build-export repo ${DIR}
+rm -rf ${DIR}