This repository was archived by the owner on Sep 2, 2024. It is now read-only.
-
-
Notifications
You must be signed in to change notification settings - Fork 69
Database provider tests clean-up #80
Copy link
Copy link
Open
Labels
good first issueGood for newcomersGood for newcomershelp wantedExtra attention is neededExtra attention is needed
Milestone
Description
There's currently 3 implementations of the Persister
database/persister.go
interface, which includes all database functions.
Each packages have the same (99%) identical tests code. For instance, cecking the number of lines in the memory
's base.go
file vs. the mongo
's one:
$ wc -l database/memory/base_test.go
406 database/memory/base_test.go
$ wc -l database/mongo/base_test.go
406 database/mongo/base_test.go
Brain storming
- Can we remove all this duplication and have one set of test that can tests all implementation?
- At the moment I created some entry in the
Makefile
to target specific database engine implementation, this is useful when implementing a new feature to only run tests for the currently develop provider. I would not want to lose this after no. 1.
Metadata
Metadata
Assignees
Labels
good first issueGood for newcomersGood for newcomershelp wantedExtra attention is neededExtra attention is needed