[PATCH 5 of 6] test-debian-packages: new test for testing construction of debian packages

timeless timeless at gmail.com
Sat Aug 29 23:28:58 CDT 2015


"It'll" is misspelled in the commit message
On Aug 27, 2015 7:31 PM, "Augie Fackler" <raf at durin42.com> wrote:

> # HG changeset patch
> # User Augie Fackler <augie at google.com>
> # Date 1440475709 14400
> #      Tue Aug 25 00:08:29 2015 -0400
> # Node ID 88da93c7840e6e65baca9941cba6d1190e66814f
> # Parent  b484b73deeb3085dbe6a91449602e4d98710c576
> test-debian-packages: new test for testing construction of debian packages
>
> This test takes over a minute to run to completion on my workstation,
> and far longer if the docker images have to be built for the first
> time on a given host. As such, the entire test is tagged as slow.
>
> The test does *not* require dpkg - it merely requires one of docker or
> dpkg be available to usefully test. On a (say) fedora machine with
> docker installed, it'l still test creating debian packages using
> docker.
>
> diff --git a/tests/test-debian-packages.t b/tests/test-debian-packages.t
> new file mode 100644
> --- /dev/null
> +++ b/tests/test-debian-packages.t
> @@ -0,0 +1,34 @@
> +#require test-repo slow
> +
> +We check debian package contents with portable tools so that when
> +we're on non-debian machines we can still test the packages that are
> +built using docker.
> +  $ checkdeb() {
> +  >   ls *.deb
> +  >   ar x mercurial*.deb
> +  >   tar tf data.tar* | grep localrepo | sort
> +  > }
> +  $ OUTPUTDIR=`pwd`
> +  $ export OUTPUTDIR
> +
> +#if docker
> +  $ cd "$TESTDIR"/..
> +  $ make docker-debian-jessie > $OUTPUTDIR/build.log 2>&1
> +  $ cd $OUTPUTDIR
> +  $ checkdeb
> +  mercurial-*.deb (glob)
> +  ./usr/lib/python2.7/site-packages/mercurial/localrepo.py
> +  ./usr/lib/python2.7/site-packages/mercurial/localrepo.pyc
> +  $ rm -f *.deb build.log
> +#endif
> +
> +#if debhelper
> +  $ cd "$TESTDIR"/..
> +  $ make debian-jessie > $OUTPUTDIR/build.log 2>&1
> +  $ cd $OUTPUTDIR
> +  $ checkdeb
> +  mercurial-*.deb (glob)
> +  ./usr/lib/python2.7/site-packages/mercurial/localrepo.py
> +  ./usr/lib/python2.7/site-packages/mercurial/localrepo.pyc
> +  $ rm -f *.deb build.log
> +#endif
> _______________________________________________
> Mercurial-devel mailing list
> Mercurial-devel at selenic.com
> https://selenic.com/mailman/listinfo/mercurial-devel
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://selenic.com/pipermail/mercurial-devel/attachments/20150830/db1f8f8b/attachment.html>


More information about the Mercurial-devel mailing list