Skip to content

Commit

Permalink
Remove a few direct DB insertions to prepare for parallel tests
Browse files Browse the repository at this point in the history
  • Loading branch information
ddworken committed Feb 10, 2024
1 parent 638912b commit f8a3552
Showing 1 changed file with 0 additions and 5 deletions.
5 changes: 0 additions & 5 deletions client/client_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -1672,12 +1672,10 @@ func setupTestTui(t testing.TB, onlineStatus OnlineStatus) (shellTester, string,
// Insert a couple hishtory entries
db := hctx.GetDb(hctx.MakeContext())
e1 := testutils.MakeFakeHistoryEntry("ls ~/")
require.NoError(t, db.Create(e1).Error)
if onlineStatus == Online {
manuallySubmitHistoryEntry(t, userSecret, e1)
}
e2 := testutils.MakeFakeHistoryEntry("echo 'aaaaaa bbbb'")
require.NoError(t, db.Create(e2).Error)
if onlineStatus == Online {
manuallySubmitHistoryEntry(t, userSecret, e2)
}
Expand Down Expand Up @@ -1793,14 +1791,11 @@ func testTui_defaultFilter(t *testing.T) {
// Setup
defer testutils.BackupAndRestore(t)()
tester, userSecret, _ := setupTestTui(t, Online)
db := hctx.GetDb(hctx.MakeContext())
e1 := testutils.MakeFakeHistoryEntry("exit 0")
e1.ExitCode = 0
require.NoError(t, db.Create(e1).Error)
manuallySubmitHistoryEntry(t, userSecret, e1)
e2 := testutils.MakeFakeHistoryEntry("exit 1")
e2.ExitCode = 1
require.NoError(t, db.Create(e2).Error)
manuallySubmitHistoryEntry(t, userSecret, e2)

// Configure a default filter
Expand Down

0 comments on commit f8a3552

Please sign in to comment.