Skip to content

Commit

Permalink
test: add a conflict resolution test with obfuscated logs
Browse files Browse the repository at this point in the history
Issue: HOTPOT-2418
  • Loading branch information
strib committed Apr 11, 2020
1 parent f5b340b commit de5b7f8
Showing 1 changed file with 17 additions and 1 deletion.
18 changes: 17 additions & 1 deletion go/kbfs/test/cr_basic_conflicts_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -7,12 +7,15 @@
package test

import (
"os"
"testing"
"time"

"github.com/keybase/client/go/kbfs/libkbfs"
)

// bob and alice both write(to the same file),
func TestCrConflictWriteFile(t *testing.T) {
func testCrConflictWriteFile(t *testing.T) {
test(t,
users("alice", "bob"),
as(alice,
Expand All @@ -39,6 +42,19 @@ func TestCrConflictWriteFile(t *testing.T) {
)
}

func TestCrConflictWriteFile(t *testing.T) {
testCrConflictWriteFile(t)
}

func TestCrConflictWriteFileWithObfuscation(t *testing.T) {
oldEnv := os.Getenv(libkbfs.EnvKeybaseTestObfuscateLogsForTest)
os.Setenv(libkbfs.EnvKeybaseTestObfuscateLogsForTest, "1")
defer func() {
os.Setenv(libkbfs.EnvKeybaseTestObfuscateLogsForTest, oldEnv)
}()
testCrConflictWriteFile(t)
}

// bob and alice both create the same entry with different types
func TestCrConflictCreateWithDifferentTypes(t *testing.T) {
test(t,
Expand Down

0 comments on commit de5b7f8

Please sign in to comment.