Skip to content

Commit 4517059

Browse files
committed
Fixed notes dao tests
1 parent ff9c59d commit 4517059

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

logicaldoc-core/src/test/java/com/logicaldoc/core/document/dao/HibernateDocumentNoteDAOTest.java

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@ public void testFindByDocId() {
4040
DocumentNote note = notes.get(0);
4141
Assert.assertEquals("message for note 1", note.getMessage());
4242
}
43-
43+
4444
@Test
4545
public void testFindByDocIdAndType() {
4646
List<DocumentNote> notes = dao.findByDocIdAndType(1L, null, "x");
@@ -53,7 +53,7 @@ public void testFindByDocIdAndType() {
5353
@Test
5454
public void testCopyAnnotations() throws PersistenceException {
5555
Assert.assertTrue(dao.findByDocId(4L, "2.0").isEmpty());
56-
dao.copyAnnotations(4L, "1.0", "2.0");
57-
Assert.assertEquals(1, dao.findByDocId(4L, "2.0").size());
56+
dao.copyAnnotations(3L, "1.0", "2.0");
57+
Assert.assertEquals(1, dao.findByDocId(3L, "2.0").size());
5858
}
5959
}

logicaldoc-core/src/test/resources/data.sql

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -400,7 +400,7 @@ insert into ld_note (ld_id, ld_lastmodified, ld_deleted, ld_docid, ld_username,
400400
values(2, '2011-04-18 00:00:00',0,1,'Admin',1,'2011-04-18 00:00:00','message for note 2',1,1,1,80,0.5,0.5,0.15,0.10,'1.0','x',1,80,0);
401401

402402
insert into ld_note (ld_id, ld_lastmodified, ld_deleted, ld_docid, ld_username, ld_userid, ld_date, ld_message,ld_tenantid,ld_recordversion,ld_page,ld_opacity,ld_top,ld_left,ld_width,ld_height,ld_fileversion,ld_linewidth,ld_lineopacity,ld_rotation)
403-
values(3, '2011-04-18 00:00:00',0,4,'John',3,'2011-04-18 00:00:00','message for note 3',1,1,0,80,0.5,0.5,0.15,0.10,'1.0',1,80,0);
403+
values(3, '2011-04-18 00:00:00',0,3,'John',3,'2011-04-18 00:00:00','message for note 3',1,1,0,80,0.5,0.5,0.15,0.10,'1.0',1,80,0);
404404

405405
insert into ld_note (ld_id, ld_lastmodified, ld_deleted, ld_docid, ld_username, ld_userid, ld_date, ld_message,ld_tenantid,ld_recordversion,ld_page,ld_opacity,ld_top,ld_left,ld_width,ld_height,ld_fileversion,ld_linewidth,ld_lineopacity,ld_rotation)
406406
values(4, '2011-04-18 00:00:00',1,1,'Admin',1,'2011-04-18 00:00:00','message for note 4',1,1,0,80,0.5,0.5,0.15,0.10,'1.0',1,80,0);

0 commit comments

Comments
 (0)