mirror of
https://github.com/usememos/memos.git
synced 2026-05-02 18:52:32 +00:00
20 lines
365 B
Go
20 lines
365 B
Go
package test
|
|
|
|
import (
|
|
"context"
|
|
"testing"
|
|
|
|
"github.com/stretchr/testify/require"
|
|
)
|
|
|
|
func TestGetDatabaseSize(t *testing.T) {
|
|
t.Parallel()
|
|
ctx := context.Background()
|
|
ts := NewTestingStore(ctx, t)
|
|
defer ts.Close()
|
|
|
|
size, err := ts.GetDriver().GetDatabaseSize(ctx)
|
|
require.NoError(t, err)
|
|
require.Greater(t, size, int64(0), "expected database size > 0")
|
|
}
|