Added hidden and favorite and test for 10.15

This commit is contained in:
Rhet Turnbull
2019-11-24 09:39:36 -08:00
parent 8b4a386c13
commit b1fd019120
22 changed files with 39 additions and 13 deletions

View File

@@ -7,7 +7,7 @@
<key>hostuuid</key>
<string>9575E48B-8D5F-5654-ABAC-4431B1167324</string>
<key>pid</key>
<integer>3490</integer>
<integer>1368</integer>
<key>processname</key>
<string>photolibraryd</string>
<key>uid</key>

View File

@@ -142,6 +142,26 @@ def test_missing():
assert p.ismissing() == True
def test_favorite():
import osxphotos
photosdb = osxphotos.PhotosDB(dbfile=PHOTOS_DB)
photos = photosdb.photos(uuid=["E9BC5C36-7CD1-40A1-A72B-8B8FAC227D51"])
assert len(photos) == 1
p = photos[0]
assert p.favorite() == True
def test_hidden():
import osxphotos
photosdb = osxphotos.PhotosDB(dbfile=PHOTOS_DB)
photos = photosdb.photos(uuid=["A1DD1F98-2ECD-431F-9AC9-5AFEFE2D3A5C"])
assert len(photos) == 1
p = photos[0]
assert p.hidden() == True
def test_count():
import osxphotos