mirror of
https://github.com/omnivore-app/omnivore.git
synced 2026-03-11 08:54:26 +00:00
Fix tests
This commit is contained in:
parent
e87b81c5c8
commit
324e0191d6
1 changed files with 5 additions and 12 deletions
|
|
@ -132,23 +132,16 @@ describe('Integrations routers', () => {
|
|||
refresh: true,
|
||||
}
|
||||
// create highlight
|
||||
const location = 109
|
||||
const patch = `@@ -${location + 1},16 +${location + 1},36 @@
|
||||
. We're
|
||||
+%3Comnivore_highlight%3E
|
||||
humbled
|
||||
@@ -254,16 +254,37 @@
|
||||
h in the
|
||||
+%3C/omnivore_highlight%3E
|
||||
coming`
|
||||
const highlightPositionPercent = 25
|
||||
highlight = {
|
||||
createdAt: new Date(),
|
||||
id: 'test id',
|
||||
patch,
|
||||
patch: 'test patch',
|
||||
quote: 'test quote',
|
||||
shortId: 'test shortId',
|
||||
updatedAt: new Date(),
|
||||
userId: user.id,
|
||||
highlightPositionPercent,
|
||||
}
|
||||
await addHighlightToPage(page.id, highlight, ctx)
|
||||
// create highlights data for integration request
|
||||
|
|
@ -162,8 +155,8 @@ describe('Integrations routers', () => {
|
|||
highlighted_at: highlight.createdAt.toISOString(),
|
||||
category: 'articles',
|
||||
image_url: page.image,
|
||||
location,
|
||||
location_type: 'page',
|
||||
location: highlightPositionPercent,
|
||||
location_type: 'order',
|
||||
note: highlight.annotation,
|
||||
source_type: 'omnivore',
|
||||
source_url: page.url,
|
||||
|
|
|
|||
Loading…
Reference in a new issue