Skip to content
This repository has been archived by the owner on Nov 17, 2021. It is now read-only.

Commit

Permalink
fix(eLife): update unit tests to support new reference format (#293)
Browse files Browse the repository at this point in the history
  • Loading branch information
discodavey committed Feb 10, 2021
1 parent 4d6d49a commit edae444
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 6 deletions.
2 changes: 1 addition & 1 deletion src/themes/elife/styles.css
Original file line number Diff line number Diff line change
Expand Up @@ -210,7 +210,7 @@

:--author {
font-size: var(--TEXT-SIZE-DEFAULT-REM);
line-height: 28px;
line-height: 27px;
}

:--authors {
Expand Down
10 changes: 5 additions & 5 deletions src/themes/elife/test/referencesFormatter.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -29,21 +29,21 @@ describe('Formatting a reference', () => {
firstReference = getFirst(references)
})

it('the title is the first element', () => {
it('the title is the second element', () => {
referencesFormatter.format(references)
expect(
getElement(firstReference, ':--title').isSameNode(
firstReference.firstElementChild
firstReference.children[2]
)
).toBe(true)
})

it('the authors follow the title', () => {
it('the title follow the authors', () => {
referencesFormatter.format(references)

expect(
getElement(firstReference, ':--authors').isSameNode(
firstReference.children[1]
firstReference.children[0]
)
).toBe(true)
})
Expand All @@ -52,7 +52,7 @@ describe('Formatting a reference', () => {

expect(
getElement(firstReference, ':--datePublished').isSameNode(
firstReference.children[2]
firstReference.children[1]
)
).toBe(true)
})
Expand Down

0 comments on commit edae444

Please sign in to comment.