From c5e5e9215e156467f2663b9679fd78adccc87697 Mon Sep 17 00:00:00 2001 From: Thomas Adamcik Date: Sun, 7 Feb 2010 04:48:34 +0100 Subject: [PATCH 1/5] Turn tests into module --- tests/__init__.py | 0 1 file changed, 0 insertions(+), 0 deletions(-) create mode 100644 tests/__init__.py diff --git a/tests/__init__.py b/tests/__init__.py new file mode 100644 index 00000000..e69de29b From 9542223f3513c1ec4fcaeb154f44f09357e87a3d Mon Sep 17 00:00:00 2001 From: Stein Magnus Jodal Date: Sun, 7 Feb 2010 13:40:38 +0100 Subject: [PATCH 2/5] Switch 'make public' from using html to dirhtml --- docs/Makefile | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/docs/Makefile b/docs/Makefile index a009cac4..4ad8691e 100644 --- a/docs/Makefile +++ b/docs/Makefile @@ -87,8 +87,8 @@ doctest: @echo "Testing of doctests in the sources finished, look at the " \ "results in _build/doctest/output.txt." -public: clean html - rm -rf /tmp/mopidy-html && cp -r _build/html /tmp/mopidy-html +public: clean dirhtml + rm -rf /tmp/mopidy-html && cp -r _build/dirhtml /tmp/mopidy-html git stash save cd .. && \ git checkout gh-pages && \ From 3302c185a0deb790d4b8fd3a1137ab223b599557 Mon Sep 17 00:00:00 2001 From: Stein Magnus Jodal Date: Sun, 7 Feb 2010 20:06:31 +0100 Subject: [PATCH 3/5] Do not include the end position in slices --- docs/api/backends.rst | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) diff --git a/docs/api/backends.rst b/docs/api/backends.rst index d5077082..6881d8d7 100644 --- a/docs/api/backends.rst +++ b/docs/api/backends.rst @@ -61,12 +61,11 @@ .. method:: move(start, end, to_position) - Move the tracks at positions in [``start``, ``end``] to - ``to_position``. + Move the tracks in the slice ``[start:end]`` to ``to_position``. :param start: position of first track to move :type start: int - :param end: position of last track to move + :param end: position after last track to move :type end: int :param to_position: new position for the tracks :type to_position: int @@ -84,12 +83,12 @@ .. method:: shuffle(start=None, end=None) - Shuffles the playlist, optionally a part of the playlist given by - ``start`` and ``end``. + Shuffles the entire playlist. If ``start`` and ``end`` is given only + shuffles the slice ``[start:end]``. :param start: position of first track to shuffle :type start: int or :class:`None` - :param end: position of last track to shuffle + :param end: position after last track to shuffle :type end: int or :class:`None` .. attribute:: version From 300e23bf11cb96fc710ac8435e2452d67ee01b9b Mon Sep 17 00:00:00 2001 From: Stein Magnus Jodal Date: Sun, 7 Feb 2010 20:14:03 +0100 Subject: [PATCH 4/5] Change play(id, position) to play(track) --- docs/api/backends.rst | 11 ++++------- 1 file changed, 4 insertions(+), 7 deletions(-) diff --git a/docs/api/backends.rst b/docs/api/backends.rst index 6881d8d7..e20578ea 100644 --- a/docs/api/backends.rst +++ b/docs/api/backends.rst @@ -125,15 +125,12 @@ Constant representing the paused state. - .. method:: play(id=None, position=None) + .. method:: play(track=None) - Play either the track with the given ID, the given position, or the - currently active track. + Play the given track or the currently active track. - :param id: ID of track to play - :type id: int - :param position: position in current playlist of track to play - :type position: int + :param track: track to play + :type track: :class:`mopidy.models.Track` or :class:`None` .. attribute:: PLAYING From 027c273442d7ef5ae5d8eb702f1e90e613468b84 Mon Sep 17 00:00:00 2001 From: Stein Magnus Jodal Date: Sun, 7 Feb 2010 20:37:30 +0100 Subject: [PATCH 5/5] pip needs sudo --- docs/development.rst | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/development.rst b/docs/development.rst index 959dcd58..2a39b327 100644 --- a/docs/development.rst +++ b/docs/development.rst @@ -34,7 +34,7 @@ To run tests, you need a couple of dependiencies. Some can be installed through The rest can be installed using pip:: sudo aptitude install python-pip python-setuptools bzr - pip install -r test-requirements.txt + sudo pip install -r test-requirements.txt Then, to run all tests::