Šarūnas Nejus
05430f312c
Move PromptChoice to beets.util module
...
And update imports that have been raising the deprecation warning.
2025-12-02 01:51:14 +00:00
Šarūnas Nejus
dd72704d3d
Do not force load musicbrainz, add a test to show the behaviour
2025-11-30 07:42:21 +00:00
Sebastian Mohr
670c300625
Fixed issue with legacy plugin copy not copying properties. Also
...
added test for it
2025-10-14 19:55:50 +02:00
Šarūnas Nejus
c0675fefb8
Merge branch 'master' into multivalued-flexible-fields
2025-08-19 13:39:34 +01:00
Šarūnas Nejus
54b31d01e9
Use only plugins/disabled_plugins config in plugin loading
2025-08-09 15:11:58 +01:00
Šarūnas Nejus
e9feb41709
Refactor plugin registration tests
2025-08-09 15:06:07 +01:00
Šarūnas Nejus
52bdb58a46
Simplify plugin loading mechanism
...
Centralise plugin loading in `beets.plugins` and refactor the plugin
loading system to be more straightforward and eliminate complex mocking
in tests. Replace the two-stage class collection and instantiation
process with direct instance creation and storage.
Add plugins.PluginImportError and adjust plugin import tests to only
complain about plugin import issues.
2025-08-09 15:06:06 +01:00
Šarūnas Nejus
788e31b619
Slightly simplify listener registration
2025-08-09 15:04:01 +01:00
Sebastian Mohr
3f23f35353
Removed duplicate importlib import.
2025-08-09 13:17:27 +02:00
Sebastian Mohr
84ae11657e
Added a check for gstream plugin issues on windows.
2025-08-09 13:17:27 +02:00
Sebastian Mohr
1696789cbe
Removed re and added brackets
2025-08-09 13:17:27 +02:00
Sebastian Mohr
a2136e1100
Removed now unused _is_spec_avilable function
2025-08-09 13:17:27 +02:00
Sebastian Mohr
8d134d1389
Skip module not found checks in favor for only running the test in
...
the ci.
2025-08-09 13:17:27 +02:00
Sebastian Mohr
586b89016b
Using fixture to unload plugins. Enhance comment. Simplified get available
...
plugins function.
2025-08-09 13:17:27 +02:00
Sebastian Mohr
8b0af15b83
Use load_plugins directly as the plugin mixin version wants
...
to create an instance which is not wanted here.
2025-08-09 13:17:27 +02:00
Sebastian Mohr
3a2b6d85a4
Using plugin mixin to unload plugins.
2025-08-09 13:17:27 +02:00
Sebastian Mohr
8aa298d646
Added module cleanup, might fix errors.
2025-08-09 13:17:27 +02:00
Sebastian Mohr
4723f3de7d
Instead of trying to import all plugins together, opted to test
...
one plugin at a time.
2025-08-09 13:17:27 +02:00
Sebastian Mohr
cfab2eb56e
Some typos
2025-08-09 13:17:27 +02:00
Sebastian Mohr
355e4d3fed
Added a load all plugins test.
2025-08-09 13:17:27 +02:00
Maxr1998
8db661b115
Add test
2025-07-16 21:46:03 +02:00
Šarūnas Nejus
509cbdcbe4
Move sanitize_pairs/choices from plugins to util module
2025-05-31 17:55:41 +01:00
Šarūnas Nejus
b520981c9c
plugins: restructure id extraction
2025-05-17 14:57:34 +01:00
Sebastian Mohr
a2e316d444
Merge remote-tracking branch 'upstream/master' into importer-restructure
2025-05-17 10:32:50 +02:00
Šarūnas Nejus
4fc9f0c3d6
Centralize AutotagStub test setup into AutotagImportTestCase
2025-05-17 03:31:58 +01:00
Sebastian Mohr
68acaa6470
Renamed all action occurrences with Action.
2025-05-13 13:01:46 +02:00
Šarūnas Nejus
c490ac5810
Fix formatting
2025-05-07 10:41:01 +01:00
Šarūnas Nejus
f36bc497c8
Fix lint issues
...
- Fix imports
- Fix pytest issues
- Do not assign lambda as variable
- Use isinstance instead of type to check type
- Rename ambiguously named variables
- Name custom errors with Error suffix
2024-09-21 11:59:18 +01:00
Šarūnas Nejus
85a17ee503
Reformat the codebase
2024-09-21 11:57:48 +01:00
Šarūnas Nejus
4b69b493d2
Use f-string syntax
2024-08-16 17:47:23 +01:00
Šarūnas Nejus
847e3858a6
Replace assertRaises
2024-08-12 08:43:42 +01:00
Šarūnas Nejus
9a05d27acf
Replace assertEqual
2024-08-12 08:43:42 +01:00
Šarūnas Nejus
6631b6aef6
Replace assertNotIn
2024-08-12 08:43:42 +01:00
Šarūnas Nejus
11e948121c
Replace assertIn
2024-08-12 08:43:42 +01:00
Šarūnas Nejus
2616bcc950
Replace assertIsNotNone
2024-08-12 08:43:41 +01:00
Šarūnas Nejus
5d4911e905
Replace assertIsNone
2024-08-12 08:43:41 +01:00
Šarūnas Nejus
cb82917fe0
Replace assertFalse
2024-08-12 08:43:41 +01:00
Šarūnas Nejus
f042f5ad32
Leave a single source of truth for importer setup
2024-07-28 18:58:53 +01:00
Šarūnas Nejus
7e444db914
Rename _create_import_dir -> prepare_album_for_import
2024-07-28 18:58:53 +01:00
Šarūnas Nejus
c2fdf9873d
Synchronise ImportHelper._create_import_dir and TestHelper.create_importer implementations
2024-07-28 18:58:53 +01:00
Šarūnas Nejus
fcff5d72af
Remove def suite TestLoader definitions
2024-07-28 18:58:51 +01:00
Šarūnas Nejus
432da560e4
Create PluginTestCase to dedupe plugin setup
2024-07-28 18:58:35 +01:00
Šarūnas Nejus
2d5fd907c3
Remove redundant setup_beets and teardown_beets instructions
2024-07-28 18:58:34 +01:00
Šarūnas Nejus
91099d362e
Deduplicate TerminalImportHelper and rename to TerminalImportMixin
2024-07-28 18:58:34 +01:00
Šarūnas Nejus
8373181e02
Create PluginImportTestCase in test_plugins
...
This involves making EventsTest use _create_import_dir from TestHelper.
2024-07-28 18:58:34 +01:00
Šarūnas Nejus
6c1e26acc9
Replace unittest.TestCase, TestHelper by BeetsTestCase
2024-07-28 18:58:34 +01:00
Šarūnas Nejus
82b1a0d01f
test_plugins.py: dedupe setUp, tearDown usage
...
And most importantly, remove a redudant invocation of `setup_beets`
which left temporary directories hanging around without getting cleaned
up.
2024-07-12 20:32:18 +01:00
freddiewanah
e0de6e1b89
refactor the test methods to avoid suboptimal asserts.
2024-04-08 21:39:25 +08:00
Lars Kruse
508d28f66b
tests: move reusable test-related modules into the beets package
...
External Python packages interfacing beets may want to use an in-memory
beets library instance for testing beets-related code.
The `TestHelper` class is very helpful for this purpose.
Previously `TestHelper` was located in the `test/` directory.
Now it is part of `beets` itself (`beets.test.helper.TestHelper`) and
can be easily imported.
2024-01-15 19:40:57 +01:00
Lars Kruse
2b99c12430
tests: move TerminalImportSessionSetup from tests.test_ui_importer to test.helper
...
This class is imported by some other test modules.
Thus, it should reside in a module, which is obviously used by other
tests.
2024-01-15 19:40:57 +01:00