Skip to content

Commit a48d2b2

Browse files
authored
Refactor har:view for better maintainability (#19)
2 parents 1e2ad6a + b8721eb commit a48d2b2

File tree

6 files changed

+156
-169
lines changed

6 files changed

+156
-169
lines changed

browser-extension/tests/test-utils.ts renamed to browser-extension/tests/har-fixture-utils.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ import path from 'node:path'
33
import { fileURLToPath } from 'node:url'
44
import type { Har as HarFile } from 'har-format'
55
import { parseHTML } from 'linkedom'
6-
import { PAGES } from './har-index'
6+
import { PAGES } from './har/_har-index'
77

88
const __dirname = path.dirname(fileURLToPath(import.meta.url))
99

browser-extension/tests/fixture-har.ts renamed to browser-extension/tests/har-fixture.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -21,8 +21,8 @@ vi.mock('../src/overtype/overtype', () => {
2121
})
2222

2323
import { describe as baseDescribe, test as baseTest, expect } from 'vitest'
24-
import type { PAGES } from './har-index'
25-
import { cleanupDOM, setupHarDOM } from './test-utils'
24+
import type { PAGES } from './har/_har-index'
25+
import { cleanupDOM, setupHarDOM } from './har-fixture-utils'
2626

2727
export const describe = baseDescribe
2828

browser-extension/tests/har-record.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
import fs from 'node:fs/promises'
22
import path from 'node:path'
33
import { chromium } from '@playwright/test'
4-
import { PAGES } from './har-index'
4+
import { PAGES } from './har/_har-index'
55

66
// Convert glob pattern to regex
77
function globToRegex(pattern: string): RegExp {

0 commit comments

Comments
 (0)