mirror of
https://github.com/mozilla/pdf.js.git
synced 2025-04-29 15:47:57 +02:00
[api-minor] Change the "dc:creator" Metadata field to an Array
- add scripting support for doc.info.authors - doc.info.metadata is the raw string with xml code
This commit is contained in:
parent
35845d1bbb
commit
43d5512f5c
10 changed files with 97 additions and 33 deletions
|
@ -451,4 +451,29 @@ describe("Interaction", () => {
|
|||
);
|
||||
});
|
||||
});
|
||||
|
||||
describe("in js-authors.pdf", () => {
|
||||
let pages;
|
||||
|
||||
beforeAll(async () => {
|
||||
pages = await loadAndWait("js-authors.pdf", "#\\32 5R");
|
||||
});
|
||||
|
||||
afterAll(async () => {
|
||||
await closePages(pages);
|
||||
});
|
||||
|
||||
it("must print authors 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("author1::author2::author3::author4::author5");
|
||||
})
|
||||
);
|
||||
});
|
||||
});
|
||||
});
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue