diff --git a/tests/test-repo.sh b/tests/test-repo.sh index b636d556..93270d18 100644 --- a/tests/test-repo.sh +++ b/tests/test-repo.sh @@ -443,12 +443,21 @@ update_repo test-gpg3 org.test.Collection.test ${FLATPAK} ${U} install -y test-repo org.test.Hello assert_file_has_content $FL_DIR/app/org.test.Hello/$ARCH/master/active/files/bin/hello.sh UPDATED +# Switch back to the old url to unconfuse other tests +UPDATE_REPO_ARGS="--redirect-url=" update_repo +${FLATPAK} ${U} remote-modify --url="http://127.0.0.1:${port}/test" test-repo + +# Also remove app so we can install the older one from the previous repo +${FLATPAK} ${U} uninstall -y org.test.Hello + ok "redirect url and gpg key" +${FLATPAK} ${U} install -y -v test-repo org.test.Hello + # Test https://github.com/flatpak/flatpak/issues/3222 mkdir -p $FL_DIR/repo/refs/mirrors/org.test.Collection.test/app/org.test.Hello/$ARCH/ cp $FL_DIR/repo/refs/remotes/test-repo/app/org.test.Hello/$ARCH/master $FL_DIR/repo/refs/mirrors/org.test.Collection.test/app/org.test.Hello/$ARCH/ -make_updated_app test-gpg3 org.test.Collection.test master UPDATE2 +make_updated_app test org.test.Collection.test master UPDATE2 ${FLATPAK} ${U} update -y org.test.Hello assert_not_has_file $FL_DIR/repo/refs/mirrors/org.test.Collection.test/app/org.test.Hello/$ARCH/master assert_has_file $FL_DIR/repo/refs/remotes/test-repo/app/org.test.Hello/$ARCH/master