Commit Graph

91 Commits

Author SHA1 Message Date
Laurent Monin
e9bd756144 Add more info to release name in other releases list if needed.
Context menu listing other releases is using main information from release,
often it is enough, but sometimes two or more items in the list are exactly
the same, user have to select each one to determine which is matching for him.

This patch is improving a bit the situation by adding packaging, barcode, or even
disambiguation comment if needed.
As an example, it often happens when a CD is released in jewel case and digipak,
with same label, date, country, barcode, etc..

Use more explicit '[no barcode]' instead of '[none]'.

A test case was added for this feature.
2013-12-06 08:43:23 +01:00
Ionuț Ciocîrlan
f1e8257d5a Merge remote-tracking branch 'upstream/master'
Conflicts:
	picard/file.py
2013-10-20 18:34:51 +03:00
Calvin Walton
769748c276 Fix the track test to include track mbid, change internal recording id name 2013-09-22 14:24:24 -04:00
Laurent Monin
ff0bd54153 Add a real life test for track number case extraction 2013-08-06 14:48:49 +02:00
Laurent Monin
2ec0631217 Use a smarter method to extract track number from filename.
When file has no metadata field indicating the track number, Picard
is trying to guess it from filename, but the simple regex wasn't very efficient.

tracknum_from_filename() does a much better job.
A test case was added.
2013-08-05 00:40:11 +02:00
Ionuț Ciocîrlan
aaab0dae48 moved filenaming stuff to its own module 2013-07-06 11:38:12 +03:00
Ionuț Ciocîrlan
b07e7f3e4d Merge remote-tracking branch 'upstream/master'
Conflicts:
	picard/util/__init__.py
	test/test_utils.py
2013-07-06 10:21:00 +03:00
Laurent Monin
7dd311697f tests: PEP8 fixes 2013-07-03 03:37:24 +02:00
Michael Wiencek
b3fcb04f9c Merge pull request #131 from zas/update_config_2
Handle configuration file versions
2013-07-02 15:06:58 -07:00
Laurent Monin
97f00b2d29 Handle configuration file versions.
version_info was renamed PICARD_VERSION
version_string was renamed PICARD_VERSION_STR
short version string is stored in PICARD_VERSION_STR_SHORT (for display)

Hooks can be created to handle upgrades (ie. options renaming), see config.register_upgrade_hook() and config.run_upgrade_hooks()
2013-07-02 01:45:25 +02:00
Laurent Monin
329ed8cedb Deprecated failUnlessAlmostEqual() -> assertAlmostEqual()
http://docs.python.org/2/library/unittest.html#deprecated-aliases
2013-07-01 13:34:53 +02:00
Laurent Monin
60ed243470 Deprecated failUnlessRaises() -> assertRaises()
http://docs.python.org/2/library/unittest.html#deprecated-aliases
2013-07-01 13:33:42 +02:00
Laurent Monin
6062fe404e Deprecated failIfEqual() -> assertNotEqual()
http://docs.python.org/2/library/unittest.html#deprecated-aliases
2013-07-01 13:31:41 +02:00
Laurent Monin
403bafbbaa Deprecated failUnlessEqual() -> assertEqual()
http://docs.python.org/2/library/unittest.html#deprecated-aliases
2013-07-01 13:29:57 +02:00
Laurent Monin
f892444998 Create a function to parse amazon urls and reduce code redundancy.
A test for amazon url parsing was added.
2013-06-30 17:25:15 +02:00
Laurent Monin
4fc84a428b Remove (now) useless data test file. 2013-06-19 19:27:10 +02:00
Laurent Monin
fdbed3f6c1 Remove fr_FR locale test, too much a requirement. 2013-06-18 12:24:09 +02:00
Ionuț Ciocîrlan
e68dc99bf6 Merge remote-tracking branch 'upstream/master' 2013-06-17 21:50:47 +03:00
Ionuț Ciocîrlan
fe8f6c2176 Characters counted in UTF-16 code points where appropriate.
NFD handled under OS X.
Windows bugfix when the relative directory path is short enough.
2013-06-17 21:42:10 +03:00
Lukáš Lalinský
b3f2e99130 Merge remote-tracking branch 'zas/info_dialog2'
Conflicts:
	picard/tagger.py
2013-06-17 08:20:42 +02:00
Ionuț Ciocîrlan
9bb1cc267d Merge remote-tracking branch 'upstream/master'
Conflicts:
	picard/file.py
2013-06-14 22:04:53 +03:00
Ionuț Ciocîrlan
1b695eea63 small fixes and some comments 2013-06-14 21:18:25 +03:00
Ionuț Ciocîrlan
6d8c912006 Merge remote-tracking branch 'upstream/master'
Conflicts:
	picard/file.py
	picard/ui/options/renaming.py
2013-06-11 19:37:10 +03:00
Sophist
2c3cb1bf02 Fix format test file 2013-06-11 16:51:26 +01:00
Ionuț Ciocîrlan
c2874ed671 tests and subsequent fixes 2013-06-11 18:19:15 +03:00
Laurent Monin
6de59d8ee9 Add functions to convert bytes to human readable form.
Binary and decimal modes are supported (MB and MiB ie.)
It supports i18n using gettext and locale.
Precision can be modified if needed, by default it is using 1 digit (if needed).

Extensive tests were written, the toughest was to make them work for
both default C locale and fr_FR.UTF-8 locale (ofc it is possible to test for more
locales...). If one locale isn't available on testing system, test is skipped.
fr locale was chosen because decimal point is replaced by a comma and byte units
becomes "octet" units (1.5 MB in english -> 1,5 Mo in french).
2013-06-09 14:23:23 +02:00
Michael Wiencek
d5509680ab Fix tests 2013-06-09 01:45:18 -05:00
Laurent Monin
b246e4b709 Reduce cover art vs formats test code redundancy. 2013-06-08 00:54:09 +02:00
Laurent Monin
5bc82bfa53 Fix tests for cover art vs formats, they couldn't fail. 2013-06-08 00:45:59 +02:00
Wieland Hoffmann
8415c360af Fix coverart tests 2012-10-20 12:05:35 +02:00
Michael Wiencek
433606f2d6 Use PyQt's new-style signal syntax 2012-09-08 00:08:45 -05:00
Michael Wiencek
4a60fbf2e6 Add a unit test for lyrics language 2012-08-17 02:48:09 -05:00
Michael Wiencek
d31b4344c1 Don't use _ as a name, try 2
I screwed up the last commit.
2012-08-16 05:00:58 -05:00
Michael Wiencek
003e808fbf Don't use _ as a name
Fixes an issue from the previous commit where I used _ as a temp
variable name. It only broke the infodialog, but I'm replacing it
everywhere just to be safe.
2012-08-16 04:39:31 -05:00
Michael Wiencek
07b710f215 Unbreak test_formats 2012-04-11 01:08:45 -05:00
Chad Wilson
abb2dc4cbe Merge branch 'master' into list_scripting_support
Conflicts:
	picard/script.py
2012-01-20 01:28:33 +08:00
Chad Wilson
76faa5b8d7 $setlist -> $setmulti (dont refer to internal data structure in name) 2012-01-20 01:07:06 +08:00
Chad Wilson
38061aeda9 Changed to do nothing on an empty splitter; ValueErrors in the log are annoying. 2012-01-20 00:55:30 +08:00
Chad Wilson
cdddc819bc failUnless -> assert (impending deprecation) 2012-01-20 00:41:58 +08:00
Chad Wilson
4cda132ad1 Add more tests for set and setlist 2012-01-20 00:40:32 +08:00
Wieland Hoffmann
51d2f2e670 fix test_utils 2012-01-16 16:30:15 +01:00
Wieland Hoffmann
12617b2101 test_mbxml: Add missing setting 2012-01-16 16:07:56 +01:00
Chad Wilson
90dc12e19a Add tests for $copy, $copymerge; improve test for $get. 2012-01-11 00:33:52 +08:00
Chad Wilson
3fac53aea3 Fix tests for release mbxml 2011-08-13 14:54:12 +08:00
Michael Wiencek
43642983a4 Make the "config" argument required for functions in mbxml.py 2011-07-14 14:46:48 -05:00
Lukáš Lalinský
0c029188a2 Primarily use track metadata, recording only as a fallback 2011-05-29 19:59:11 +02:00
Michael Wiencek
720ea96e25 Replace unittests in test_mbxml.py and modify functions in mbxml.py to parse the new XML for tracks (recordings) and releases. 2011-05-19 11:21:21 -05:00
Philipp Wolfer
1567d802c3 Added UI to set preferred release types. 2011-05-13 00:15:39 +02:00
Philipp Wolfer
e442bdac31 Prefer release events with a date and sort release events accordingly. 2010-05-24 23:00:04 +02:00
Philipp Wolfer
552f1640cb Changed cover art test case to use data > 64kb to test for current bug in mutagen with ASF files. 2010-04-15 23:54:28 +02:00