zotero/test/tests/data/mendeleyMock/items-simple.json
Tom Najdek 141258d564 Fix a bug in regex extracting fields to "extra"
Because regex is built using a template string, \s* is actually escaped
into s*, i.e. literal "s" appearing 0 or more times. In most cases this
would mean that output can have spacing slightly off. In extreme case,
when identifier starts with letter "s", this could this could lead to
identifier being stored incorrectly.

Also adjusted tests to be more strict and mock data to cover this case.
2022-08-11 02:46:37 -04:00

88 lines
No EOL
2.6 KiB
JSON

[
{
"authored": false,
"confirmed": true,
"created": "2021-11-02T09:54:28.353Z",
"file_attached": false,
"hidden": false,
"id": "7fea3cb3-f97d-3f16-8fad-f59caaa71688",
"last_modified": "2021-11-02T12:26:30.025Z",
"private_publication": false,
"profile_id": "8dbf0832-8723-4c48-b532-20c0b7f6e01a",
"read": false,
"source": "lorem ipsum",
"identifiers":
{
"doi": "10.1111",
"pmid": "PMID: 11111111",
"arxiv": "1111.2222"
},
"starred": false,
"title": "Foo Bar",
"authors":
[
{
"first_name": "Tom",
"last_name": "Najdek"
},
{
"first_name": "Lorem",
"last_name": "Ipsum"
}
],
"type": "journal",
"folder_uuids": [
"8d2f262d-49b3-4dfc-8968-0bb71bcd92ea"
],
"year": 1987
}, {
"authored": false,
"confirmed": true,
"created": "2021-11-04T11:53:10.353Z",
"file_attached": false,
"hidden": false,
"id": "07a74c26-28d1-4d9f-a60d-3f3bc5ef76ef",
"last_modified": "2021-11-04T11:53:10.353Z",
"private_publication": false,
"profile_id": "8dbf0832-8723-4c48-b532-20c0b7f6e01a",
"read": false,
"starred": false,
"title": "Sample Report",
"type": "report",
"year": 2002
}, {
"title": "Item with PDF",
"type": "journal",
"year": 2005,
"source": "Zotero",
"pages": "1-11",
"websites":
[
"https://zotero.org"
],
"id": "c54b0c6f-c4ce-4706-8742-bc7d032df862",
"created": "2021-11-09T10:26:15.201Z",
"file_attached": true,
"profile_id": "8dbf0832-8723-4c48-b532-20c0b7f6e01a",
"last_modified": "2021-11-09T10:26:16.303Z",
"read": false,
"starred": false,
"authored": false,
"confirmed": true,
"hidden": false,
"private_publication": false,
"abstract": "Lorem Ipsum. Nostrud elit ullamco laborum cillum.",
"files":
[
{
"id": "19fb5e5b-1a39-4851-b513-d48441a670e1",
"document_id": "c54b0c6f-c4ce-4706-8742-bc7d032df862",
"mime_type": "application/pdf",
"file_name": "item.pdf",
"size": 123456,
"created": "2021-11-09T10:26:16.292Z",
"filehash": "cc22c6611277df346ff8dc7386ba3880b2bafa15"
}
]
}
]