feat: add CRUD operations for artist_settings table
Implements GetArtistSettings, SaveArtistSettings, GetAllArtistSettings, and UpdateArtistSettings with full test coverage (10 new tests). All 17 database tests pass. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -87,14 +87,14 @@ Build the foundation layer of NaviWatcher: a greenfield Go project with zero exi
|
||||
- [x] run tests — must pass before task 4
|
||||
|
||||
### Task 4: Database layer — CRUD operations for artist_settings
|
||||
- [ ] implement `GetArtistSettings(db *DB, id string) (*ArtistSettings, error)`
|
||||
- [ ] implement `SaveArtistSettings(db *DB, settings *ArtistSettings) error`
|
||||
- [ ] implement `GetAllArtistSettings(db *DB) ([]ArtistSettings, error)`
|
||||
- [ ] implement `UpdateArtistSettings(db *DB, id string, updates map[string]interface{}) error`
|
||||
- [ ] write tests for GetArtistSettings (found and not found cases)
|
||||
- [ ] write tests for SaveArtistSettings (insert and update)
|
||||
- [ ] write tests for GetAllArtistSettings (empty and populated)
|
||||
- [ ] run tests — must pass before task 5
|
||||
- [x] implement `GetArtistSettings(db *DB, id string) (*ArtistSettings, error)`
|
||||
- [x] implement `SaveArtistSettings(db *DB, settings *ArtistSettings) error`
|
||||
- [x] implement `GetAllArtistSettings(db *DB) ([]ArtistSettings, error)`
|
||||
- [x] implement `UpdateArtistSettings(db *DB, id string, updates map[string]interface{}) error`
|
||||
- [x] write tests for GetArtistSettings (found and not found cases)
|
||||
- [x] write tests for SaveArtistSettings (insert and update)
|
||||
- [x] write tests for GetAllArtistSettings (empty and populated)
|
||||
- [x] run tests — must pass before task 5
|
||||
|
||||
### Task 5: Database layer — CRUD operations for external_releases
|
||||
- [ ] implement `GetExternalRelease(db *DB, rgid string) (*ExternalRelease, error)`
|
||||
|
||||
Reference in New Issue
Block a user