mirror of
https://github.com/hedgedoc/hedgedoc.git
synced 2024-11-25 11:16:31 -05:00
test: fix "creates a new revision" test
Signed-off-by: Philip Molares <philip.molares@udo.edu>
This commit is contained in:
parent
231a3fd6bd
commit
d3249c6635
1 changed files with 4 additions and 4 deletions
|
@ -199,7 +199,7 @@ describe('RevisionsService', () => {
|
||||||
|
|
||||||
describe('createRevision', () => {
|
describe('createRevision', () => {
|
||||||
it('creates a new revision', async () => {
|
it('creates a new revision', async () => {
|
||||||
const note = Mock.of<Note>({});
|
const note = Mock.of<Note>({ publicId: 'test-note' });
|
||||||
const oldContent = 'old content\n';
|
const oldContent = 'old content\n';
|
||||||
const newContent = 'new content\n';
|
const newContent = 'new content\n';
|
||||||
|
|
||||||
|
@ -216,10 +216,10 @@ describe('RevisionsService', () => {
|
||||||
expect(createdRevision?.content).toBe(newContent);
|
expect(createdRevision?.content).toBe(newContent);
|
||||||
await expect(createdRevision?.note).resolves.toBe(note);
|
await expect(createdRevision?.note).resolves.toBe(note);
|
||||||
expect(createdRevision?.patch).toMatchInlineSnapshot(`
|
expect(createdRevision?.patch).toMatchInlineSnapshot(`
|
||||||
"Index: markdownContent
|
"Index: test-note
|
||||||
===================================================================
|
===================================================================
|
||||||
--- markdownContent
|
--- test-note
|
||||||
+++ markdownContent
|
+++ test-note
|
||||||
@@ -1,1 +1,1 @@
|
@@ -1,1 +1,1 @@
|
||||||
-old content
|
-old content
|
||||||
+new content
|
+new content
|
||||||
|
|
Loading…
Reference in a new issue