chore(runtime): upgrade DSH and bundled plugins for runtime-7.11
This commit is contained in:
@@ -30,15 +30,15 @@ test('patch rejects unsupported or changed clients and double patching', () => {
|
||||
'await fetch(`/plugins/dsh-session-delete/${action}`, options); await response.json()',
|
||||
"await fetch('/plugins/dsh-session-delete/archive-search', options); await response.json()",
|
||||
].join(';');
|
||||
const patched = patchClient(source, '1.5.18');
|
||||
const patched = patchClient(source, '1.5.20');
|
||||
assert.equal(patched.split('await dshChatFetch(').length, 4);
|
||||
assert.equal(patched.slice(clientHelpers.length).replaceAll('await dshChatFetch(', 'await fetch(')
|
||||
.replaceAll('await dshChatJson(response)', 'await response.json()'), source);
|
||||
assert.throws(() => patchClient(source, '1.5.16'), /unsupported/);
|
||||
assert.throws(() => patchClient(source, '1.5.13'), /unsupported/);
|
||||
assert.throws(() => patchClient('', '1.5.18'), /unexpected/);
|
||||
assert.throws(() => patchClient(source.replace('await fetch(', 'fetch('), '1.5.18'), /unexpected/);
|
||||
assert.throws(() => patchClient(source.replace('await response.json()', 'response.json()'), '1.5.18'), /unexpected/);
|
||||
assert.throws(() => patchClient(source.replace('/plugins/dsh-session-delete/', '/plugins/changed/'), '1.5.18'), /unexpected/);
|
||||
assert.throws(() => patchClient(patched, '1.5.18'), /unexpected/);
|
||||
assert.throws(() => patchClient('', '1.5.20'), /unexpected/);
|
||||
assert.throws(() => patchClient(source.replace('await fetch(', 'fetch('), '1.5.20'), /unexpected/);
|
||||
assert.throws(() => patchClient(source.replace('await response.json()', 'response.json()'), '1.5.20'), /unexpected/);
|
||||
assert.throws(() => patchClient(source.replace('/plugins/dsh-session-delete/', '/plugins/changed/'), '1.5.20'), /unexpected/);
|
||||
assert.throws(() => patchClient(patched, '1.5.20'), /unexpected/);
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user