mirror of
https://github.com/zen-browser/pdf.js.git
synced 2025-07-08 09:20:06 +02:00
[api-minor] Implement securityHandler in the scripting API (bug 1731578)
This commit is contained in:
parent
1ab9a6e36e
commit
91fc643ff9
7 changed files with 32 additions and 1 deletions
|
@ -896,4 +896,26 @@ describe("Interaction", () => {
|
|||
);
|
||||
});
|
||||
});
|
||||
|
||||
describe("in secHandler.pdf", () => {
|
||||
let pages;
|
||||
|
||||
beforeAll(async () => {
|
||||
pages = await loadAndWait("secHandler.pdf", "#\\32 5R");
|
||||
});
|
||||
|
||||
afterAll(async () => {
|
||||
await closePages(pages);
|
||||
});
|
||||
it("must print securityHandler value in a text field", async () => {
|
||||
await Promise.all(
|
||||
pages.map(async ([browserName, page]) => {
|
||||
const text = await actAndWaitForInput(page, "#\\32 5R", async () => {
|
||||
await page.click("[data-annotation-id='26R']");
|
||||
});
|
||||
expect(text).withContext(`In ${browserName}`).toEqual("Standard");
|
||||
})
|
||||
);
|
||||
});
|
||||
});
|
||||
});
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue