mirror of
https://github.com/dylanaraps/pywal.git
synced 2025-01-08 15:09:38 +01:00
tests: Fix tests
This commit is contained in:
parent
d8376eecc9
commit
a0c130cbda
@ -1,2 +1,5 @@
|
|||||||
[BASIC]
|
[BASIC]
|
||||||
good-names=i3
|
good-names=i3
|
||||||
|
|
||||||
|
[SIMILARITIES]
|
||||||
|
ignore-imports=yes
|
||||||
|
@ -10,7 +10,7 @@ from . import util
|
|||||||
from . import wallpaper
|
from . import wallpaper
|
||||||
|
|
||||||
|
|
||||||
def get_random_image(img_dir, cache_dir):
|
def get_random_image(img_dir):
|
||||||
"""Pick a random image file from a directory."""
|
"""Pick a random image file from a directory."""
|
||||||
current_wall = wallpaper.get()
|
current_wall = wallpaper.get()
|
||||||
current_wall = os.path.basename(current_wall[0])
|
current_wall = os.path.basename(current_wall[0])
|
||||||
@ -34,7 +34,7 @@ def get(img, cache_dir=__cache_dir__):
|
|||||||
wal_img = str(image)
|
wal_img = str(image)
|
||||||
|
|
||||||
elif image.is_dir():
|
elif image.is_dir():
|
||||||
wal_img = get_random_image(image, cache_dir)
|
wal_img = get_random_image(image)
|
||||||
|
|
||||||
else:
|
else:
|
||||||
print("error: No valid image file found.")
|
print("error: No valid image file found.")
|
||||||
|
Loading…
Reference in New Issue
Block a user