[PATCH 3 of 5] byteify-strings: add test for byteify-strings.py
Yuya Nishihara
yuya at tcha.org
Fri Aug 2 20:46:50 EDT 2019
On Fri, 02 Aug 2019 17:01:24 +0200, Raphaël Gomès wrote:
> # HG changeset patch
> # User Raphaël Gomès <rgomes at octobus.net>
> # Date 1564757642 -7200
> # Fri Aug 02 16:54:02 2019 +0200
> # Node ID 91a17ea759c5f0fceaae18fb558435ab379faac7
> # Parent fea16ec00093e73bf0aa4db3f2a709c385fc6336
> # EXP-Topic byteify-strings
> byteify-strings: add test for byteify-strings.py
>
> This tests the basic features expected from this script, some cases may not
> be covered yet.
>
> A future patch will demonstrate an issue with multi-line `(`, `[` and `{`
> alignment and propose a fix.
>
> diff -r fea16ec00093 -r 91a17ea759c5 tests/test-byteify-strings.t
> --- /dev/null Thu Jan 01 00:00:00 1970 +0000
> +++ b/tests/test-byteify-strings.t Fri Aug 02 16:54:02 2019 +0200
> @@ -0,0 +1,195 @@
Needs #require py3
> +Test in-place
> +
> + $ cat > testfile.py <<EOF
> + > obj['test'] = b"1234"
> + > mydict.iteritems()
> + > EOF
> + $ python $BINDIR/contrib/byteify-strings.py testfile.py -i
Probably better to use $PYTHON.
And it should be $TESTDIR/../contrib. You can add a shell function.
$ byteify-strings () {
> $PYTHON "$TESTDIR/../contrib/byteify-strings.py" "$@"
> }
More information about the Mercurial-devel
mailing list