about summary refs log tree commit diff
path: root/nixpkgs/pkgs/development/libraries/flatpak/fix-test-paths.patch
diff options
context:
space:
mode:
authorAlyssa Ross <hi@alyssa.is>2019-02-07 15:19:21 +0000
committerAlyssa Ross <hi@alyssa.is>2019-02-07 23:35:47 +0000
commite5013c05a2f845255debf94318ab38ecef1c186b (patch)
treebec11a0bd31d3432a16899e5539f1098f1c168a4 /nixpkgs/pkgs/development/libraries/flatpak/fix-test-paths.patch
parent4fc07c92ec07cafcf6d56143ea7334693143ef88 (diff)
parent2d2f10475138b7206572dc3ec288184df2be022e (diff)
downloadnixlib-e5013c05a2f845255debf94318ab38ecef1c186b.tar
nixlib-e5013c05a2f845255debf94318ab38ecef1c186b.tar.gz
nixlib-e5013c05a2f845255debf94318ab38ecef1c186b.tar.bz2
nixlib-e5013c05a2f845255debf94318ab38ecef1c186b.tar.lz
nixlib-e5013c05a2f845255debf94318ab38ecef1c186b.tar.xz
nixlib-e5013c05a2f845255debf94318ab38ecef1c186b.tar.zst
nixlib-e5013c05a2f845255debf94318ab38ecef1c186b.zip
Merge commit '2d2f10475138b7206572dc3ec288184df2be022e'
Diffstat (limited to 'nixpkgs/pkgs/development/libraries/flatpak/fix-test-paths.patch')
-rw-r--r--nixpkgs/pkgs/development/libraries/flatpak/fix-test-paths.patch38
1 files changed, 28 insertions, 10 deletions
diff --git a/nixpkgs/pkgs/development/libraries/flatpak/fix-test-paths.patch b/nixpkgs/pkgs/development/libraries/flatpak/fix-test-paths.patch
index d00e4fa7f895..f987899e3bcb 100644
--- a/nixpkgs/pkgs/development/libraries/flatpak/fix-test-paths.patch
+++ b/nixpkgs/pkgs/development/libraries/flatpak/fix-test-paths.patch
@@ -1,14 +1,14 @@
 --- a/tests/libtest.sh
 +++ b/tests/libtest.sh
-@@ -296,7 +296,7 @@
-         # running installed-tests: assume we know what we're doing
-         :
-     elif ! "$FLATPAK_BWRAP" --unshare-ipc --unshare-net --unshare-pid \
--            --ro-bind / / /bin/true > bwrap-result 2>&1; then
-+            --ro-bind / / @coreutils@/bin/true > bwrap-result 2>&1; then
-         sed -e 's/^/# /' < bwrap-result
-         echo "1..0 # SKIP Cannot run bwrap"
-         exit 0
+@@ -328,7 +328,7 @@
+     # running installed-tests: assume we know what we're doing
+     _flatpak_bwrap_works=true
+ elif ! "$FLATPAK_BWRAP" --unshare-ipc --unshare-net --unshare-pid \
+-        --ro-bind / / /bin/true > bwrap-result 2>&1; then
++        --ro-bind / / @coreutils@/bin/true > bwrap-result 2>&1; then
+     _flatpak_bwrap_works=false
+ else
+     _flatpak_bwrap_works=true
 @@ -309,12 +309,12 @@
  export DBUS_SESSION_BUS_ADDRESS="$(cat dbus-session-bus-address)"
  DBUS_SESSION_BUS_PID="$(cat dbus-session-bus-pid)"
@@ -24,6 +24,24 @@
      gpg-connect-agent --homedir "${FL_GPG_HOMEDIR}" killagent /bye || true
      fusermount -u $XDG_RUNTIME_DIR/doc || :
      if test -n "${TEST_SKIP_CLEANUP:-}"; then
+--- a/tests/make-test-app.sh
++++ b/tests/make-test-app.sh
+@@ -114,13 +114,13 @@ msgid "Hello world"
+ msgstr "Hallo Welt"
+ EOF
+ mkdir -p ${DIR}/files/de/share/de/LC_MESSAGES
+-msgfmt --output-file ${DIR}/files/de/share/de/LC_MESSAGES/helloworld.mo de.po
++@gettext@/bin/msgfmt --output-file ${DIR}/files/de/share/de/LC_MESSAGES/helloworld.mo de.po
+ cat > fr.po <<EOF
+ msgid "Hello world"
+ msgstr "Bonjour le monde"
+ EOF
+ mkdir -p ${DIR}/files/fr/share/fr/LC_MESSAGES
+-msgfmt --output-file ${DIR}/files/fr/share/fr/LC_MESSAGES/helloworld.mo fr.po
++@gettext@/bin/msgfmt --output-file ${DIR}/files/fr/share/fr/LC_MESSAGES/helloworld.mo fr.po
+ 
+ flatpak build-finish ${DIR}
+ mkdir -p repos
 --- a/tests/make-test-runtime.sh
 +++ b/tests/make-test-runtime.sh
 @@ -26,6 +26,7 @@
@@ -61,7 +79,7 @@
 -    fi
 -}
 -
- for i in $@; do
+ for i in $@ bash ls cat echo readlink; do
 -    I=`which $i`
 -    add_bin $I
 -done