Append DOI fields to project bibliography entries
.format_bib_entry ignored the doi field, so the arXiv first reference lost its doi:10.1109/... suffix. Append doi:<value> when present and extend the server bib test fixture/assertions. Test count stays 1078.
This commit is contained in:
1 parent
eb2cb561bd
commit
1b0f4c8ab3
3 files changed
+7
-2
No files matched your search
+2
-1
@@ -1223,7 +1223,7 @@ fn project_preview_resolves_bibtex() {
|
||||
"text/plain; charset=utf-8",
|
||||
);
|
||||
assert_eq!(put.status, 200, "{}", put.text());
|
||||
let bib = "@article{alpha,\n title={Alpha entry},\n author={Doe, Jane},\n year={2024}\n}\n";
|
||||
let bib = "@article{alpha,\n title={Alpha entry},\n author={Doe, Jane},\n year={2024},\n doi={10.1000/test}\n}\n";
|
||||
let put = server.request(
|
||||
"PUT",
|
||||
"/api/projects/hello/file?path=refs.bib",
|
||||
@@ -1255,6 +1255,7 @@ fn project_preview_resolves_bibtex() {
|
||||
assert!(text.contains("References"), "{text}");
|
||||
assert!(text.contains("Doe,2024"), "{text}");
|
||||
assert!(text.contains("Alphaentry"), "{text}");
|
||||
assert!(text.contains("doi:10.1000/test"), "{text}");
|
||||
assert!(!text.contains("[?]"), "{text}");
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user