mirror of
https://github.com/moonD4rk/HackBrowserData.git
synced 2026-05-19 18:58:03 +02:00
feat: add CountEntries to skip decryption for list --detail (#562)
* feat: add CountEntries to skip decryption for list --detail (#549) * test: add CountEntries and countCategory tests at browser level * fix: address review feedback on CountRows and countLocalStorage * test: add CountRows unit tests
This commit is contained in:
@@ -141,6 +141,14 @@ func insertWebappsstore(originKey, key, value string) string {
|
||||
// Test fixture builders
|
||||
// ---------------------------------------------------------------------------
|
||||
|
||||
// installFile copies a test fixture file into a profile directory.
|
||||
func installFile(t *testing.T, profileDir, srcPath, dstName string) {
|
||||
t.Helper()
|
||||
data, err := os.ReadFile(srcPath)
|
||||
require.NoError(t, err)
|
||||
require.NoError(t, os.WriteFile(filepath.Join(profileDir, dstName), data, 0o644))
|
||||
}
|
||||
|
||||
func createTestDB(t *testing.T, name string, schemas []string, inserts ...string) string {
|
||||
t.Helper()
|
||||
path := filepath.Join(t.TempDir(), name)
|
||||
|
||||
Reference in New Issue
Block a user