forked from Mirrors/flatpak-builder
Fix update of standalone bundle
We regressed on being able to install a bundle twice to update it. This fixes https://github.com/flatpak/flatpak/issues/462tingping/wmclass
parent
5c2999fe20
commit
c4f0f3245d
|
@ -467,7 +467,7 @@ flatpak_transaction_add_ref (FlatpakTransaction *self,
|
|||
}
|
||||
remote = origin;
|
||||
}
|
||||
else
|
||||
else if (kind == FLATPAK_TRANSACTION_OP_KIND_INSTALL)
|
||||
{
|
||||
g_assert (remote != NULL);
|
||||
if (dir_ref_is_installed (self->dir, ref, NULL))
|
||||
|
|
|
@ -24,7 +24,7 @@ set -euo pipefail
|
|||
skip_without_bwrap
|
||||
skip_without_user_xattrs
|
||||
|
||||
echo "1..6"
|
||||
echo "1..7"
|
||||
|
||||
mkdir bundles
|
||||
|
||||
|
@ -147,3 +147,19 @@ run org.test.Hello > hello_out
|
|||
assert_file_has_content hello_out '^Hello world, from a sandboxUPDATED$'
|
||||
|
||||
echo "ok update"
|
||||
|
||||
make_updated_app UPDATED2
|
||||
|
||||
${FLATPAK} build-bundle repos/test --repo-url=file://`pwd`/repos/test --gpg-keys=${FL_GPG_HOMEDIR}/pubring.gpg bundles/hello2.flatpak org.test.Hello
|
||||
assert_has_file bundles/hello2.flatpak
|
||||
|
||||
${FLATPAK} install ${U} -y --bundle bundles/hello2.flatpak
|
||||
|
||||
NEW2_COMMIT=`${FLATPAK} ${U} info --show-commit org.test.Hello`
|
||||
|
||||
assert_not_streq "$NEW_COMMIT" "$NEW2_COMMIT"
|
||||
|
||||
run org.test.Hello > hello_out
|
||||
assert_file_has_content hello_out '^Hello world, from a sandboxUPDATED2$'
|
||||
|
||||
echo "ok update as bundle"
|
||||
|
|
Loading…
Reference in New Issue