allusion-app / Allusion

A free and open source desktop application for managing your visual library
GNU General Public License v3.0
698 stars 47 forks source link

Backend Refactor #590

Closed hummingly closed 1 year ago

hummingly commented 1 year ago

There are many features that need some prototyping in the backend but the code quality has degraded over time as we made many changes. Furthermore, there are also many subtle bugs and performance issues due to us not using transactions. This PR does not fix all issues but it will resolve bugs where files refer to deleted locations and/or tags. Plus testing should be easier as mocking was replaced with just passing dependencies to the constructors and indexeddb is replaced with an in-memory implementation for tests. For future tests, jest.mock should be avoided as it is a sign of poor API design on our side.