Skip to content

Commit

Permalink
Merge pull request #48 from EchoVault/chore/echovault-test
Browse files Browse the repository at this point in the history
Added longer yields for file sync after snapshot and aof rewrite
  • Loading branch information
kelvinmwinuka authored Jun 10, 2024
2 parents 4912a21 + 62bf589 commit 3534ce6
Show file tree
Hide file tree
Showing 3 changed files with 59 additions and 61 deletions.
114 changes: 57 additions & 57 deletions coverage/coverage.out
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,61 @@ github.com/echovault/echovault/internal/config/config.go:247.2,249.45 2 0
github.com/echovault/echovault/internal/config/config.go:249.45,251.3 1 0
github.com/echovault/echovault/internal/config/config.go:253.2,253.18 1 0
github.com/echovault/echovault/internal/config/default.go:8.29,38.2 1 0
github.com/echovault/echovault/internal/aof/preamble/store.go:45.62,46.36 1 1
github.com/echovault/echovault/internal/aof/preamble/store.go:46.36,48.3 1 1
github.com/echovault/echovault/internal/aof/preamble/store.go:51.71,52.36 1 0
github.com/echovault/echovault/internal/aof/preamble/store.go:52.36,54.3 1 0
github.com/echovault/echovault/internal/aof/preamble/store.go:57.88,58.36 1 1
github.com/echovault/echovault/internal/aof/preamble/store.go:58.36,60.3 1 1
github.com/echovault/echovault/internal/aof/preamble/store.go:63.95,64.36 1 1
github.com/echovault/echovault/internal/aof/preamble/store.go:64.36,66.3 1 1
github.com/echovault/echovault/internal/aof/preamble/store.go:69.65,70.36 1 1
github.com/echovault/echovault/internal/aof/preamble/store.go:70.36,72.3 1 1
github.com/echovault/echovault/internal/aof/preamble/store.go:75.86,81.52 1 1
github.com/echovault/echovault/internal/aof/preamble/store.go:81.52,84.4 1 0
github.com/echovault/echovault/internal/aof/preamble/store.go:85.60,85.61 0 0
github.com/echovault/echovault/internal/aof/preamble/store.go:88.2,88.33 1 1
github.com/echovault/echovault/internal/aof/preamble/store.go:88.33,90.3 1 1
github.com/echovault/echovault/internal/aof/preamble/store.go:93.2,93.46 1 1
github.com/echovault/echovault/internal/aof/preamble/store.go:93.46,95.17 2 1
github.com/echovault/echovault/internal/aof/preamble/store.go:95.17,97.4 1 0
github.com/echovault/echovault/internal/aof/preamble/store.go:98.3,99.17 2 1
github.com/echovault/echovault/internal/aof/preamble/store.go:99.17,101.4 1 0
github.com/echovault/echovault/internal/aof/preamble/store.go:102.3,102.15 1 1
github.com/echovault/echovault/internal/aof/preamble/store.go:105.2,105.19 1 1
github.com/echovault/echovault/internal/aof/preamble/store.go:108.52,115.16 5 1
github.com/echovault/echovault/internal/aof/preamble/store.go:115.16,117.3 1 0
github.com/echovault/echovault/internal/aof/preamble/store.go:120.2,120.44 1 1
github.com/echovault/echovault/internal/aof/preamble/store.go:120.44,122.3 1 0
github.com/echovault/echovault/internal/aof/preamble/store.go:124.2,124.46 1 1
github.com/echovault/echovault/internal/aof/preamble/store.go:124.46,126.3 1 0
github.com/echovault/echovault/internal/aof/preamble/store.go:128.2,128.44 1 1
github.com/echovault/echovault/internal/aof/preamble/store.go:128.44,130.3 1 0
github.com/echovault/echovault/internal/aof/preamble/store.go:133.2,133.39 1 1
github.com/echovault/echovault/internal/aof/preamble/store.go:133.39,135.3 1 0
github.com/echovault/echovault/internal/aof/preamble/store.go:137.2,137.12 1 1
github.com/echovault/echovault/internal/aof/preamble/store.go:140.45,141.21 1 1
github.com/echovault/echovault/internal/aof/preamble/store.go:141.21,143.3 1 0
github.com/echovault/echovault/internal/aof/preamble/store.go:146.2,146.47 1 1
github.com/echovault/echovault/internal/aof/preamble/store.go:146.47,148.3 1 0
github.com/echovault/echovault/internal/aof/preamble/store.go:150.2,151.16 2 1
github.com/echovault/echovault/internal/aof/preamble/store.go:151.16,153.3 1 0
github.com/echovault/echovault/internal/aof/preamble/store.go:155.2,155.17 1 1
github.com/echovault/echovault/internal/aof/preamble/store.go:155.17,157.3 1 0
github.com/echovault/echovault/internal/aof/preamble/store.go:159.2,161.49 2 1
github.com/echovault/echovault/internal/aof/preamble/store.go:161.49,163.3 1 0
github.com/echovault/echovault/internal/aof/preamble/store.go:165.2,165.56 1 1
github.com/echovault/echovault/internal/aof/preamble/store.go:165.56,167.3 1 1
github.com/echovault/echovault/internal/aof/preamble/store.go:169.2,169.12 1 1
github.com/echovault/echovault/internal/aof/preamble/store.go:172.43,176.2 3 0
github.com/echovault/echovault/internal/aof/preamble/store.go:179.110,181.26 2 1
github.com/echovault/echovault/internal/aof/preamble/store.go:181.26,182.36 1 1
github.com/echovault/echovault/internal/aof/preamble/store.go:182.36,183.12 1 0
github.com/echovault/echovault/internal/aof/preamble/store.go:185.3,185.43 1 1
github.com/echovault/echovault/internal/aof/preamble/store.go:185.43,187.4 1 1
github.com/echovault/echovault/internal/aof/preamble/store.go:189.2,189.35 1 1
github.com/echovault/echovault/internal/aof/preamble/store.go:189.35,191.3 1 1
github.com/echovault/echovault/internal/aof/preamble/store.go:192.2,192.14 1 1
github.com/echovault/echovault/internal/aof/log/store.go:46.60,47.34 1 1
github.com/echovault/echovault/internal/aof/log/store.go:47.34,49.3 1 1
github.com/echovault/echovault/internal/aof/log/store.go:52.61,53.34 1 1
Expand Down Expand Up @@ -97,61 +152,6 @@ github.com/echovault/echovault/internal/aof/log/store.go:193.2,193.47 1 0
github.com/echovault/echovault/internal/aof/log/store.go:193.47,195.3 1 0
github.com/echovault/echovault/internal/aof/log/store.go:196.2,196.12 1 0
github.com/echovault/echovault/internal/aof/log/store.go:199.41,203.2 3 1
github.com/echovault/echovault/internal/aof/preamble/store.go:45.62,46.36 1 1
github.com/echovault/echovault/internal/aof/preamble/store.go:46.36,48.3 1 1
github.com/echovault/echovault/internal/aof/preamble/store.go:51.71,52.36 1 0
github.com/echovault/echovault/internal/aof/preamble/store.go:52.36,54.3 1 0
github.com/echovault/echovault/internal/aof/preamble/store.go:57.88,58.36 1 1
github.com/echovault/echovault/internal/aof/preamble/store.go:58.36,60.3 1 1
github.com/echovault/echovault/internal/aof/preamble/store.go:63.95,64.36 1 1
github.com/echovault/echovault/internal/aof/preamble/store.go:64.36,66.3 1 1
github.com/echovault/echovault/internal/aof/preamble/store.go:69.65,70.36 1 1
github.com/echovault/echovault/internal/aof/preamble/store.go:70.36,72.3 1 1
github.com/echovault/echovault/internal/aof/preamble/store.go:75.86,81.52 1 1
github.com/echovault/echovault/internal/aof/preamble/store.go:81.52,84.4 1 0
github.com/echovault/echovault/internal/aof/preamble/store.go:85.60,85.61 0 0
github.com/echovault/echovault/internal/aof/preamble/store.go:88.2,88.33 1 1
github.com/echovault/echovault/internal/aof/preamble/store.go:88.33,90.3 1 1
github.com/echovault/echovault/internal/aof/preamble/store.go:93.2,93.46 1 1
github.com/echovault/echovault/internal/aof/preamble/store.go:93.46,95.17 2 1
github.com/echovault/echovault/internal/aof/preamble/store.go:95.17,97.4 1 0
github.com/echovault/echovault/internal/aof/preamble/store.go:98.3,99.17 2 1
github.com/echovault/echovault/internal/aof/preamble/store.go:99.17,101.4 1 0
github.com/echovault/echovault/internal/aof/preamble/store.go:102.3,102.15 1 1
github.com/echovault/echovault/internal/aof/preamble/store.go:105.2,105.19 1 1
github.com/echovault/echovault/internal/aof/preamble/store.go:108.52,115.16 5 1
github.com/echovault/echovault/internal/aof/preamble/store.go:115.16,117.3 1 0
github.com/echovault/echovault/internal/aof/preamble/store.go:120.2,120.44 1 1
github.com/echovault/echovault/internal/aof/preamble/store.go:120.44,122.3 1 0
github.com/echovault/echovault/internal/aof/preamble/store.go:124.2,124.46 1 1
github.com/echovault/echovault/internal/aof/preamble/store.go:124.46,126.3 1 0
github.com/echovault/echovault/internal/aof/preamble/store.go:128.2,128.44 1 1
github.com/echovault/echovault/internal/aof/preamble/store.go:128.44,130.3 1 0
github.com/echovault/echovault/internal/aof/preamble/store.go:133.2,133.39 1 1
github.com/echovault/echovault/internal/aof/preamble/store.go:133.39,135.3 1 0
github.com/echovault/echovault/internal/aof/preamble/store.go:137.2,137.12 1 1
github.com/echovault/echovault/internal/aof/preamble/store.go:140.45,141.21 1 1
github.com/echovault/echovault/internal/aof/preamble/store.go:141.21,143.3 1 0
github.com/echovault/echovault/internal/aof/preamble/store.go:146.2,146.47 1 1
github.com/echovault/echovault/internal/aof/preamble/store.go:146.47,148.3 1 0
github.com/echovault/echovault/internal/aof/preamble/store.go:150.2,151.16 2 1
github.com/echovault/echovault/internal/aof/preamble/store.go:151.16,153.3 1 0
github.com/echovault/echovault/internal/aof/preamble/store.go:155.2,155.17 1 1
github.com/echovault/echovault/internal/aof/preamble/store.go:155.17,157.3 1 0
github.com/echovault/echovault/internal/aof/preamble/store.go:159.2,161.49 2 1
github.com/echovault/echovault/internal/aof/preamble/store.go:161.49,163.3 1 0
github.com/echovault/echovault/internal/aof/preamble/store.go:165.2,165.56 1 1
github.com/echovault/echovault/internal/aof/preamble/store.go:165.56,167.3 1 1
github.com/echovault/echovault/internal/aof/preamble/store.go:169.2,169.12 1 1
github.com/echovault/echovault/internal/aof/preamble/store.go:172.43,176.2 3 0
github.com/echovault/echovault/internal/aof/preamble/store.go:179.110,181.26 2 1
github.com/echovault/echovault/internal/aof/preamble/store.go:181.26,182.36 1 1
github.com/echovault/echovault/internal/aof/preamble/store.go:182.36,183.12 1 0
github.com/echovault/echovault/internal/aof/preamble/store.go:185.3,185.43 1 1
github.com/echovault/echovault/internal/aof/preamble/store.go:185.43,187.4 1 1
github.com/echovault/echovault/internal/aof/preamble/store.go:189.2,189.35 1 1
github.com/echovault/echovault/internal/aof/preamble/store.go:189.35,191.3 1 1
github.com/echovault/echovault/internal/aof/preamble/store.go:192.2,192.14 1 1
github.com/echovault/echovault/internal/aof/engine.go:50.56,51.30 1 1
github.com/echovault/echovault/internal/aof/engine.go:51.30,53.3 1 1
github.com/echovault/echovault/internal/aof/engine.go:56.57,57.30 1 1
Expand Down Expand Up @@ -352,7 +352,7 @@ github.com/echovault/echovault/internal/modules/hash/commands.go:301.38,303.17 2
github.com/echovault/echovault/internal/modules/hash/commands.go:303.17,304.41 1 1
github.com/echovault/echovault/internal/modules/hash/commands.go:304.41,306.13 2 1
github.com/echovault/echovault/internal/modules/hash/commands.go:308.4,308.42 1 1
github.com/echovault/echovault/internal/modules/hash/commands.go:308.42,311.13 3 0
github.com/echovault/echovault/internal/modules/hash/commands.go:308.42,311.13 3 1
github.com/echovault/echovault/internal/modules/hash/commands.go:313.4,313.38 1 1
github.com/echovault/echovault/internal/modules/hash/commands.go:313.38,315.13 2 1
github.com/echovault/echovault/internal/modules/hash/commands.go:320.2,320.25 1 1
Expand Down Expand Up @@ -1131,7 +1131,7 @@ github.com/echovault/echovault/internal/modules/set/commands.go:251.75,253.16 2
github.com/echovault/echovault/internal/modules/set/commands.go:253.16,255.3 1 0
github.com/echovault/echovault/internal/modules/set/commands.go:257.2,261.37 3 1
github.com/echovault/echovault/internal/modules/set/commands.go:261.37,262.14 1 1
github.com/echovault/echovault/internal/modules/set/commands.go:262.14,264.4 1 0
github.com/echovault/echovault/internal/modules/set/commands.go:262.14,264.4 1 1
github.com/echovault/echovault/internal/modules/set/commands.go:265.3,266.10 2 1
github.com/echovault/echovault/internal/modules/set/commands.go:266.10,269.4 1 1
github.com/echovault/echovault/internal/modules/set/commands.go:270.3,270.27 1 1
Expand Down
2 changes: 0 additions & 2 deletions echovault/api_acl_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -598,8 +598,6 @@ func TestEchoVault_ACLConfig(t *testing.T) {

for _, test := range tests {
t.Run(test.name, func(t *testing.T) {
t.Parallel()

// Create server.
conf := DefaultConfig()
conf.DataDir = ""
Expand Down
4 changes: 2 additions & 2 deletions internal/modules/admin/commands_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -788,7 +788,7 @@ func Test_AdminCommands(t *testing.T) {
}

// Yield to allow snapshot to complete sync.
ticker := time.NewTicker(20 * time.Millisecond)
ticker := time.NewTicker(200 * time.Millisecond)
<-ticker.C
ticker.Stop()

Expand Down Expand Up @@ -829,7 +829,7 @@ func Test_AdminCommands(t *testing.T) {
t.Run("Test REWRITEAOF command", func(t *testing.T) {
t.Parallel()

ticker := time.NewTicker(100 * time.Millisecond)
ticker := time.NewTicker(200 * time.Millisecond)

dataDir := path.Join(".", "testdata", "test_aof")
t.Cleanup(func() {
Expand Down

0 comments on commit 3534ce6

Please sign in to comment.