From 8328b5dd4a74dbcd61cd77c3dd56c456089c9517 Mon Sep 17 00:00:00 2001 From: boojack Date: Wed, 26 Jul 2023 22:42:38 +0800 Subject: [PATCH] chore: upgrade version to `0.14.2` (#2035) * chore: upgrade version to `0.14.2` * chore: remove TestConcurrentReadWrite test --- server/version/version.go | 4 ++-- test/store/store_test.go | 46 --------------------------------------- 2 files changed, 2 insertions(+), 48 deletions(-) diff --git a/server/version/version.go b/server/version/version.go index d7be9ae9..b6ec176c 100644 --- a/server/version/version.go +++ b/server/version/version.go @@ -9,10 +9,10 @@ import ( // Version is the service current released version. // Semantic versioning: https://semver.org/ -var Version = "0.14.1" +var Version = "0.14.2" // DevVersion is the service current development version. -var DevVersion = "0.14.1" +var DevVersion = "0.14.2" func GetCurrentVersion(mode string) string { if mode == "dev" || mode == "demo" { diff --git a/test/store/store_test.go b/test/store/store_test.go index b82a1ad3..47e99ce6 100644 --- a/test/store/store_test.go +++ b/test/store/store_test.go @@ -1,47 +1 @@ package teststore - -import ( - "context" - "fmt" - "sync" - "testing" - - "github.com/stretchr/testify/require" - "github.com/usememos/memos/store" -) - -func TestConcurrentReadWrite(t *testing.T) { - ctx := context.Background() - ts := NewTestingStore(ctx, t) - user, err := createTestingHostUser(ctx, ts) - require.NoError(t, err) - - const numWorkers = 10 - const numIterations = 100 - - wg := sync.WaitGroup{} - wg.Add(numWorkers) - - for i := 0; i < numWorkers; i++ { - go func() { - for j := 0; j < numIterations; j++ { - _, err := ts.CreateMemo(ctx, &store.Memo{ - CreatorID: user.ID, - Content: fmt.Sprintf("test_content_%d", i), - Visibility: store.Public, - }) - require.NoError(t, err) - } - }() - - go func() { - _, err := ts.ListMemos(ctx, &store.FindMemo{ - CreatorID: &user.ID, - }) - require.NoError(t, err) - wg.Done() - }() - } - - wg.Wait() -}