Commit graph

27 commits

Author SHA1 Message Date
Andrew Rogl
5859d31405 Commit #4036 2021-09-26 16:41:13 +10:00
Andrew Rogl
1ec87a3bdd pyupgrade beetsplug and tests
All tests working
More tidy up to be done
2021-08-26 19:12:51 +10:00
Adrian Sampson
a88682e7bb Undo from _common import unittest indirection
This was a vestige from when we used to need the unittest2 library for pre-2.7
compatibility. Now that we require Python 2.7, we aren't using that library
and this indirection wasn't doing any good.
2016-11-26 18:46:44 -05:00
Johnny Robeson
8c1e9e0dd4 add missing displayable_paths to satisify python -bb 2016-07-03 23:52:05 -04:00
Adrian Sampson
890b9e81e3 Fix #2089: correct permissions configuration
This reverts the change in 44380db6e8, where we
lost the ability to "reinterpret" decimals in the YAML configuration file as
octal permissions values.
2016-06-28 10:51:13 -07:00
Johnny Robeson
ebff5a599c treat filenames as bytestrings in perm plugin tests 2016-06-14 01:29:35 -04:00
Johnny Robeson
ef727854f1 treat default perms as str in permission plugin tests 2016-06-14 01:28:13 -04:00
Adrian Sampson
90f4c77ea0 Skip permissions tests on Windows 2016-06-06 11:54:23 -07:00
Adrian Sampson
71b9fd785c Revert "Do __name__ comparison with bytes and not unicode"
This reverts commit 9c41c39913.
That commit used byte strings for the `if __name__ == '__main__'` pattern,
which was necessary when we were doing unicode_literals. But it is wrong on
Python 3, and now that we're liberated from unicode_literals, we need to go
back to native strings for this comparison.
2016-05-29 19:19:59 -07:00
Jack Wilsdon
b1c58e99ec Update code to match pep8 naming standards 2016-04-27 20:15:10 +01:00
Adrian Sampson
e54c7eec3d Standardize __future__ imports without parentheses
Since the list is short enough now, we don't need parentheses for the line
wrap. This is a little less ugly.
2016-02-28 15:03:51 -08:00
Peter Kessen
9fffd26267 Removed unicode_literals from test_permissions 2016-02-24 07:35:11 +01:00
Jesse Weinstein
78b81fc8b8 apparently do_test is a magic name. Who knew? 2016-01-05 00:35:01 -08:00
Jesse Weinstein
cce2d5450f Adjust test_permissions to handle different starting perms 2016-01-05 00:28:43 -08:00
Jesse Weinstein
edefc1373e Bring test_permissions.py up to 100% 2016-01-04 23:42:14 -08:00
Peter Kessen
6b408507f6 added encoding as comment in files
added line like
# -*- coding: utf-8 -*-
to all files without license
2015-11-19 18:52:57 +01:00
Raymond Wanyoike
2490863042 Fix unicode paths in permissions test 2015-08-03 16:21:46 +03:00
Marvin Steadfast
dd0de2f04b Made the permissions plugin simpler. Got rid of some non-needed code and use the ancestors function instead of writing something new. 2015-02-17 11:41:15 +01:00
Marvin Steadfast
21aedeb51a Updated permissions plugin to change directory permissions too. 2015-02-17 11:41:15 +01:00
Bruno Cauet
53c21330c2 All tests use unicode_literals 2015-01-20 15:58:02 +01:00
Bruno Cauet
9c41c39913 Do __name__ comparison with bytes and not unicode 2015-01-20 12:03:57 +01:00
Bruno Cauet
90b388b775 Use __future__ imports but unicode_literals everywhere
Include import of __future__ features division, absolute_imports and
print_function everywhere. Don't add unicode_literals yet for it is
harder to convert.

Goal is smoothing the transition to python 3.
2015-01-19 12:25:16 +01:00
Bruno Cauet
2902cda036 tests: use absolute imports everywhere 2015-01-19 12:25:15 +01:00
Adrian Sampson
42228e6d82 Tests: fix unload_plugins
Don't mutate the base classes. This was causing plugins to break on the second
test that uses them, since after they were unloaded their class-level fields
were broken (since the modules are not re-loaded).

This makes it more clear than ever that we need to encapsulate plugin loading
state using some manner of PluginManager.
2014-11-24 10:58:32 -08:00
Marvin Steadfast
d3b76d83d2 Permissions plugins listens now for album_imported and item_imported 2014-11-24 18:41:50 +01:00
Marvin Steadfast
8784e8d8ca plugin now listens for item_copied instead of after_write. now the test works 2014-11-20 11:40:02 +01:00
Marvin Steadfast
a01e73d813 added not working test for debugging 2014-11-19 19:43:31 +01:00