Commit Graph
98 Commits
Author SHA1 Message Date
Sebastian Mohr 54a2bd20e1 Removed This file is part of beets... headers. 2026-06-29 11:20:15 +02:00
Šarūnas Nejus 132cd55e21 Remove unused plugin test helpers
- Dropped unused MusicBrainZ and Subsonic test helpers and imports.
- Keeps plugin test modules focused on the behavior they still exercise.
2026-06-17 18:56:27 +01:00
Šarūnas Nejus 648f24cbc2 Enable and fix flake8-builtins 2026-06-09 00:14:06 +01:00
David Logie 621a401226 Simplify test. 2026-05-29 17:25:00 +01:00
David Logie 9c51b5c109 PR feedback. 2026-05-29 17:25:00 +01:00
David Logie 785f8b7a5c Make aliases-as-credits functionality opt-in.
This feature was introduced in 2.10 but results a lot of data being
overwritten with (potentially) incorrect data the next time a user runs
`mbsync` over their library.

To make this less of a "breaking" change, make this feature opt-in. The
users who want this large change can enable the functionality.
2026-05-29 17:25:00 +01:00
Martin Caspersen c2f8c65193 style: apply ruff formatting to test 2026-05-29 16:54:23 +02:00
Martin Caspersen 31e18b2c4c refactor(musicbrainz): use direct aliases access and improve browse test
Replace defensive .get("aliases", []) with recording["aliases"] now that
"aliases" is in BROWSE_INCLUDES. Swap the graceful-fallback test for one
that asserts aliases from browse results take priority over the track title.
2026-05-29 16:50:23 +02:00
Martin CaspersenandClaude Sonnet 4.6 ba798ae281 style: apply ruff formatting and address review comments
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-27 15:25:18 +02:00
Martin CaspersenandClaude Sonnet 4.6 beb1610476 fix(musicbrainz): handle missing aliases in browse_recordings for large releases
When a release exceeds BROWSE_MAXTRACKS tracks, _ensure_complete_recordings
fetches recordings via browse_recordings. BROWSE_INCLUDES was missing "aliases",
so the API never returned alias data, causing a KeyError in get_tracks_from_medium.

Add "aliases" to BROWSE_INCLUDES and defensively use .get("aliases", []) at the
access site, consistent with all other alias lookups in the file.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-27 13:45:17 +02:00
Sebastian Mohr adfb73b66d Run ruff format 2026-05-20 16:53:06 +02:00
ShimmerGlass cc63a4e9b9 fix(MusicBrainz): date parsing fix
Correctly handle release dates where leading or
intermediate components are missing, e.g. 2008-??-02
2026-05-02 16:26:48 +02:00
Eric Masseran 567a83fc74 No condition in tests 2026-04-19 12:28:07 +02:00
Eric Masseran 363b681421 Add alias on artist credit release and track 2026-04-19 10:54:34 +02:00
Šarūnas Nejus 34517120b9 Add a single data-driven recording test 2026-04-18 19:29:33 +01:00
Šarūnas Nejus c27b69e030 Reorganise tests 2026-04-18 17:31:50 +01:00
Šarūnas Nejus cffb4d28fe Remove redundant artist credit test 2026-04-18 17:31:50 +01:00
Šarūnas Nejus 652f74b8f4 Simplify test get date 2026-04-18 17:31:49 +01:00
Šarūnas Nejus 7d2ffd0309 Simplify pseudo release lookup 2026-04-18 17:31:49 +01:00
Šarūnas Nejus a5189a0014 Test album criteria completely 2026-04-18 17:31:49 +01:00
Šarūnas Nejus 4ada3b5e50 Refactor and test fetching complete recording data 2026-04-18 17:31:49 +01:00
Šarūnas Nejus 6b8c0974bc Test pregap track 2026-04-18 17:31:49 +01:00
Šarūnas Nejus 595aee27ad Simplify media tests 2026-04-18 17:31:49 +01:00
Šarūnas Nejus 76c55cc74c Test URL relations parsing 2026-04-18 17:31:49 +01:00
Šarūnas Nejus 92078ec756 Move test_parse_release under TestParse 2026-04-18 17:31:49 +01:00
Šarūnas Nejus 8c35f45d60 Test parsing label infos fully 2026-04-18 17:31:49 +01:00
Šarūnas Nejus 245f45eba4 Extend artist credits parsing coverage 2026-04-18 17:31:49 +01:00
Šarūnas Nejus ffd98a9f79 Simplify aliases tests 2026-04-18 17:31:49 +01:00
Šarūnas Nejus 4bc5498663 Simplify genres tests 2026-04-18 17:31:49 +01:00
Šarūnas Nejus 0f486f9117 Simplify preferred_alias tests 2026-04-18 17:31:49 +01:00
Šarūnas Nejus 93dd413a70 Collapse data tracks tests into a single test 2026-04-18 17:31:49 +01:00
Šarūnas Nejus 93b0cfde48 Collapse many tests into a single data-driven test 2026-04-18 17:31:49 +01:00
Šarūnas Nejus 7e52bea0f5 Fix typing issues in tests 2026-04-18 17:31:49 +01:00
Šarūnas Nejus a5368a16f4 Make use of ReleaseFactory 2026-04-18 17:31:49 +01:00
Šarūnas Nejus 39c515ce75 Introduce ReleaseFactory 2026-04-18 17:31:49 +01:00
Šarūnas Nejus 817b90fb6f Refactor medium parsing 2026-04-18 17:31:49 +01:00
Šarūnas Nejus 1965c0746c Refactor parsing medium track 2026-04-18 17:31:49 +01:00
Šarūnas Nejus bca79cbbe5 Use RecordingFactory in tests 2026-04-18 17:31:49 +01:00
Šarūnas Nejus 0d15952c7a Enforce asin, disambiguation, fix status 2026-04-18 17:31:49 +01:00
Šarūnas Nejus f611ae6968 Refactor parsing language and script 2026-04-18 17:31:49 +01:00
Šarūnas Nejus bff84bbd06 Refactor parsing label info 2026-04-18 17:31:49 +01:00
Šarūnas Nejus 7cafb250e6 Refactor parsing genre 2026-04-18 17:31:49 +01:00
Šarūnas Nejus 0b0f715121 Use ReleaseGroupFactory 2026-04-18 17:31:49 +01:00
Šarūnas Nejus befcf6a63b Refactor date parsing 2026-04-18 17:31:49 +01:00
Šarūnas Nejus 5b32661f17 Refactor _preferred_release_event 2026-04-18 17:31:49 +01:00
Šarūnas Nejus 9ec85d1ba2 Use artist_relation_factory 2026-04-18 17:31:49 +01:00
Šarūnas Nejus c5519de8d0 Use ArtistFactory 2026-04-18 17:31:49 +01:00
Šarūnas Nejus 486cd99540 Remove _artist_ids 2026-04-18 17:31:49 +01:00
Šarūnas Nejus 0ed87af0b9 Use ArtistCreditFactory for test artist_credit construction 2026-04-18 17:31:48 +01:00
Šarūnas Nejus d7fd707ca5 Simplify multi artist credit parsing 2026-04-18 17:31:48 +01:00