このコミットが含まれているのは:
2026-07-18 23:38:16 +09:00
コミット 46e6d94edb
4個のファイルの変更32行の追加8行の削除
+4 -4
ファイルの表示
@@ -29,15 +29,15 @@ describe ('post new review URL state', () => {
.toEqual (['one', 'two'])
})
it ('allows at most a 4095-byte request target', () => {
it ('allows at most a 6 143 byte request target', () => {
const baseUrl = 'https://example.com/'
const baseLength = postNewReviewPathByteLength ([baseUrl])
const allowed = `${ baseUrl }${ 'a'.repeat (4_095 - baseLength) }`
const allowed = `${ baseUrl }${ 'a'.repeat (6_143 - baseLength) }`
const denied = `${ allowed }a`
expect (postNewReviewPathByteLength ([allowed])).toBe (4_095)
expect (postNewReviewPathByteLength ([allowed])).toBe (6_143)
expect (isPostNewReviewPathWithinLimit ([allowed])).toBe (true)
expect (postNewReviewPathByteLength ([denied])).toBe (4_096)
expect (postNewReviewPathByteLength ([denied])).toBe (6_144)
expect (isPostNewReviewPathWithinLimit ([denied])).toBe (false)
})
})
+1 -1
ファイルの表示
@@ -1,5 +1,5 @@
const POST_NEW_REVIEW_PATH_PREFIX = '/posts/new?urls='
const MAX_POST_NEW_REVIEW_TARGET_BYTES = 4_096
const MAX_POST_NEW_REVIEW_TARGET_BYTES = 6_144
const textEncoder = new TextEncoder ()
+1 -1
ファイルの表示
@@ -60,7 +60,7 @@ describe ('PostImportSourcePage', () => {
const input = screen.getByRole ('textbox', { name: '' })
fireEvent.change (input, {
target: { value: `https://example.com/${ 'a'.repeat (4_100) }` } })
target: { value: `https://example.com/${ 'a'.repeat (6_200) }` } })
expect (screen.getByRole ('button', { name: '次へ' })).toBeDisabled ()
})