Commit Graph

1458 Commits

Author SHA1 Message Date
Lasse Bigum
093c0400a9 Fix review comments 2013-11-08 21:43:31 +01:00
Lasse Bigum
03750a8bf2 Fix scan with multiple track artists and add tests 2013-11-08 21:25:21 +01:00
Thomas Adamcik
469f414c4c audio: Don't do duration conversion to ms in scanner 2013-11-06 19:10:49 +01:00
Thomas Adamcik
20b0602842 audio/scanner: Move translator into audio.
Tries to move more of the gst bits and pieces we are leaking into audio.
2013-11-06 19:10:49 +01:00
Thomas Adamcik
0a2d74eff1 scanner: Update to use new mopidy.audio.scan
Also adds the check less than 100ms check back to the scanner.
2013-11-06 19:10:49 +01:00
Lasse Bigum
9593da08b6 Rename track in MPD to track_name to avoid confusion 2013-11-02 22:34:26 +01:00
Stein Magnus Jodal
838f584e2b local: Formatting 2013-11-02 22:18:37 +01:00
Stein Magnus Jodal
b0d43444c2 local: Remove debug logging in tests 2013-11-02 22:18:26 +01:00
Lasse Bigum
f295cbd3cb Fix flake8 issues 2013-11-02 22:14:25 +01:00
Lasse Bigum
24944bd8e3 Split artist and albumartist dependency, update tests based on this 2013-11-02 22:13:54 +01:00
Lasse Bigum
86f18935fe Fix flake8 errors and add a few more tests 2013-11-02 21:57:53 +01:00
Lasse Bigum
fd213f2d78 Add tests for albumartist 2013-11-02 21:57:53 +01:00
Lasse Bigum
e7746dac1b Remove debug, make track_no more robust 2013-11-02 21:54:46 +01:00
Lasse Bigum
efc9fc75b5 Fix track_no 2013-11-02 21:49:44 +01:00
Stein Magnus Jodal
04d9fa667b deps: Don't strip last dir from dependency path 2013-11-02 19:25:06 +01:00
Stein Magnus Jodal
c3a9bc06ed Bump version for development 2013-10-27 22:44:10 +01:00
Stein Magnus Jodal
9064fc02fd Merge branch 'develop' into feature/mpd-search-by-albumartist
Conflicts:
	mopidy/frontends/mpd/protocol/music_db.py
	mopidy/frontends/mpd/translator.py
2013-10-27 21:30:58 +01:00
Stein Magnus Jodal
be6e6c9a93 local: Readd lost test assertion 2013-10-27 21:26:26 +01:00
Stein Magnus Jodal
c42dd1bf1d mpd: Add 'find track ""' test to match search tests 2013-10-27 21:23:45 +01:00
Stein Magnus Jodal
d13d9958b0 mpd: Formatting 2013-10-27 21:22:57 +01:00
Stein Magnus Jodal
f7e85b1f12 Merge branch 'develop' into feature/track_and_count 2013-10-27 21:04:09 +01:00
Stein Magnus Jodal
f9c09a8990 Merge pull request #548 from adamcik/feature/write-config
Prep work for adding a `mopidy config --set ...` type command.
2013-10-27 12:52:46 -07:00
Stein Magnus Jodal
24a2b08fc5 mpd: Don't return fake artists when searching by albumartist 2013-10-27 20:24:07 +01:00
Stein Magnus Jodal
dabddd81fd mpd: Accept 'albumartist' type to 'find' and 'search' commands 2013-10-27 20:22:45 +01:00
Thomas Adamcik
ecc0bae344 local: Delete uris in library refresh (fixes #500)
Makes sure we remove uri's that can no longer be found in the tag cache.
2013-10-27 14:10:56 +01:00
Thomas Adamcik
73f91710e1 config: Add postprocessor for converting config back.
Idea forward from here is that once we have a config sub command that we expose
a setting config values which will:

1. Run the preprocessor on the file to edit.
2. Load it into config parser.
3. Modify the value.
4. Write it to a io.ByteString
5. Run the postprocessor
6. Save the file with comments etc intact.
2013-10-27 12:30:02 +01:00
Thomas Adamcik
d5cb4282d9 config: Add preprocessor for preserving comments when editing configs.
Adds markers to configs files that ensures configparser won't mangle comments
in the files. Will be combined with a postprocessor that undoes these changes.
2013-10-27 11:38:01 +01:00
Stein Magnus Jodal
b0ae7d3c6f local: Fix crash on non-ASCII chars in URIs 2013-10-24 23:22:01 +02:00
Stein Magnus Jodal
e448d77eb7 mpd: Fix flipped mute logic 2013-10-24 22:20:07 +02:00
Lasse Bigum
457c39fc78 Remove duplicate test group, merge it into existing 2013-10-22 23:40:38 +02:00
Lasse Bigum
95046b4852 Fix small bug and fix test 2013-10-22 00:12:32 +02:00
Lasse Bigum
1975694d08 Changed track to track_no, fix code, add tests
Added testcases for track and count
2013-10-20 23:04:48 +02:00
Thomas Adamcik
84c373d7ea Merge branch 'develop' into fix/bug-496-handle-single
Conflicts:
	mopidy/core/tracklist.py
2013-10-20 22:46:35 +02:00
Thomas Adamcik
f1f223bba8 local: Fix handling of single in eot_track (fixes #496)
- Adds test cases for code paths that caused bug
- Short circuits EOT next track handling when in single mode.
2013-10-20 21:43:19 +02:00
Thomas Adamcik
7fc753d167 core/local: Update playback test with review comments.
- Fixes typo.
- Adds assert to better test intermediate state.
2013-10-20 21:16:18 +02:00
Thomas Adamcik
d978005008 core: flake8 fixes 2013-10-20 20:33:48 +02:00
Thomas Adamcik
40754bb2e0 core: Fix handling of shuffle (fixes #453)
- Shuffle internal list when random is enabled
- Use presence of tl_track to determine if this is first run to trigger
  subsequent shuffles.
2013-10-20 19:28:13 +02:00
Thomas Adamcik
66ae1b8eee local/core: Add and fix more random related tests.
- Adds tests for eot_track vs next_track as we were only testing the one code
  path.
- Makes test_random_until_end_of_playlist_and_play_from_start actually test
  random and not repeat.
- Adds test_play_track_then_enable_random which is the underlying bug covered
  by the regression test for issue #17.
2013-10-20 18:39:07 +02:00
Thomas Adamcik
025bafc114 local/core: Update random tests to be more predictable
- Replace setting the random seed with mocking out shuffle with reverse. This
  makes tests easier to reason about while still being able to test correct
  behaviour.
- Increases number of tracks to four to avoid test passing due to symetry in
  plain and reversed lists.
- Made test_eot_track_with_random_after_append_playlist actually test eot and
  not next.
- Found a test failure in handling of test_random_until_end_of_playlist, fix in
  next commit.
2013-10-20 18:39:07 +02:00
Stein Magnus Jodal
96008ca826 Merge pull request #539 from adamcik/fix/bug-527-temp-workaround
local: Temporary workaround for issue #527
2013-10-20 07:31:55 -07:00
Thomas Adamcik
fcd3e5d5cf local: Add test for fallback handling of unknown track uris in playlists
- Checks that adding a non local:track:... uri to a playlist and reading it
  back works.
- Also fixes mistake in API usage where we assumed lookup still raised
  LookupError.
2013-10-20 16:18:03 +02:00
Stein Magnus Jodal
c8886dec49 tests: Sort imports 2013-10-20 16:04:09 +02:00
Thomas Adamcik
2f01fc4e46 scanner: Review comments and flake fixes
- Move ScannerError to exceptions module.
- Subclass ScannerError from MopidyException.
- Fix import sorting.
2013-10-20 15:51:39 +02:00
Thomas Adamcik
a5a55952fb scanner: Switch to gst.pbutils.Discoverer and refactor API
- New API wraps gst.pbutils.Discoverer for mopidy use.
  - Custom scanner code removed.
- Callback based async API switched with simpler synchronous API
  - Scanner is feed one and one URI and returns the result or raises an error.
- Adds new ScannerError exception for error handling in scanner
- Limits local/scan_timeout to 1000-3600000 i.e. 1s to 1h
- Files with zero duration are now excluded.
- Mtime handling moved out of scanner so we can use it for streams etc.
2013-10-20 13:22:00 +02:00
Thomas Adamcik
e0bfe144f8 Merge pull request #532 from jodal/feature/search-by-albumartist
Search filtering by albumartist
2013-10-19 13:46:58 -07:00
Thomas Adamcik
c8f5c1aacf Merge pull request #537 from jodal/tidy-up-core
Core playback and tracklist modularity improvement v2
2013-10-19 13:24:21 -07:00
Stein Magnus Jodal
27a63b1688 local: Remove redundant test asserts 2013-10-19 22:17:08 +02:00
Stein Magnus Jodal
c850ed2698 Merge branch 'develop' into feature/search-by-albumartist
Conflicts:
	tests/backends/local/library_test.py
2013-10-19 22:15:50 +02:00
Stein Magnus Jodal
7d874873bd local: Include albumartist in 'any' searches 2013-10-19 22:14:53 +02:00
Stein Magnus Jodal
033e3ab813 jsonrpc: Test application error responses again
The test was modified to not fail after a refactoring, making it not test what
it was intended to test at all. This reverts the changes and updates the test
in another way, keeping the original intention.
2013-10-19 20:53:02 +02:00