mirror of
https://github.com/ddworken/hishtory.git
synced 2025-06-21 20:41:39 +02:00
Update testTui setup function to ensure that entries are also added in the remote server and not just locally, to ensure they show up post-sync
This commit is contained in:
parent
434acd3738
commit
7b02d6f2a2
@ -1741,8 +1741,12 @@ func setupTestTui(t testing.TB) (shellTester, string, *gorm.DB) {
|
|||||||
|
|
||||||
// Insert a couple hishtory entries
|
// Insert a couple hishtory entries
|
||||||
db := hctx.GetDb(hctx.MakeContext())
|
db := hctx.GetDb(hctx.MakeContext())
|
||||||
testutils.Check(t, db.Create(testutils.MakeFakeHistoryEntry("ls ~/")).Error)
|
e1 := testutils.MakeFakeHistoryEntry("ls ~/")
|
||||||
testutils.Check(t, db.Create(testutils.MakeFakeHistoryEntry("echo 'aaaaaa bbbb'")).Error)
|
testutils.Check(t, db.Create(e1).Error)
|
||||||
|
manuallySubmitHistoryEntry(t, userSecret, e1)
|
||||||
|
e2 := testutils.MakeFakeHistoryEntry("echo 'aaaaaa bbbb'")
|
||||||
|
testutils.Check(t, db.Create(e2).Error)
|
||||||
|
manuallySubmitHistoryEntry(t, userSecret, e2)
|
||||||
return tester, userSecret, db
|
return tester, userSecret, db
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user